• php开发常用指令集合


    配置git环境配置:
    git config  –global user.name "Hoewang"


    git config   -global user.email "37407409@qq.com"

    $ ssh-keygen -t rsa -C “37407409@qq.com”

    Github那边:settings->ssh keys->输入id_rsa.pub文件里面的内容(通过cd ~/.ssh)看文件


    常用项目交互:
    git init //把这个目录变成Git可以管理的仓库


    git add README.md //文件添加到仓库


    git add . //不但可以跟单一文件,还可以跟通配符,更可以跟目录。一个点就把当前目录下所有未追踪的文件全部add了


    git commit -m "first commit" //把文件提交到仓库


    git remote add origin git@github.com:Hoewang/practice.git //关联远程仓库


    git push -u origin master //把本地库的所有内容推送到远程库上


    更改后的:
    1.git status
    2.添加修改过的文件到索引库(git add -u)
    3.再次检测(git status)
    4.将修改从暂存区提交到本地版本库(git commit -m “modify”)
    5.从远程获取最新版本并merge到本地(git pull)
    6.将本地版本库的分支推送到远程服务器上对应的分支(git push)
    开启memcache:
    /usr/local/memcache/bin/memcached -umemcache & 
    Linux:
    设置系统时间:
    date -s 10/10/17 设置日期
    date -s 09:54:00 设置时间
    1. 设置系统时间与网络时间同步

    # ntpdate cn.pool.ntp.org

    2. 将系统时间写入硬件时间

    # hwclock --systohc
    1.开启先运行这个文件的内容:
    vim /etc/rc.local
    //类似构造函数
    2.apache的所谓www目录
    /usr/local/apache2/htdocs
    3.apache主配置
    /usr/local/apache2/etc/httpd.conf
    4.apache子配置
    /usr/local/apache2/etc/extra/httpd-vhosts.conf
    5.操作起别名
    vim /root/.bashrc
      alias sta=’/usr/local/apache2/bin/apachectl start’
                alias sto=’/usr/local/apache2/bin/apachectl stop’
    source /root/.bashrc  //载入这个配置
      6.php配置
    /usr/local/php/etc/php.ini
      7.追加环境变量
        vim /etc/profile
    在最后一行加上 export PATH="/usr/local/php/bin:$PATH"
                       export PATH="/usr/local/mysql/bin:$PATH"
      source /etc/profile
    防火墙:
    iptables -F
        iptables -X
        Iptables -Z
    检测查询:
    1.重启服务器 service network restart
    2.检测apache是否启动 netstat –tlunp | grep 80
    3.检测mysql是否启动 netstat –tlunp | grep 3306
    4.检测远程 netstat – tlunp | grep 22
  • 相关阅读:
    Populating Next Right Pointers in Each Node II
    Populating Next Right Pointers in Each Node
    Construct Binary Tree from Preorder and Inorder Traversal
    Construct Binary Tree from Inorder and Postorder Traversal
    Path Sum
    Symmetric Tree
    Solve Tree Problems Recursively
    632. Smallest Range(priority_queue)
    609. Find Duplicate File in System
    poj3159最短路spfa+邻接表
  • 原文地址:https://www.cnblogs.com/hoewang/p/10257264.html
Copyright © 2020-2023  润新知