- 在github创建仓库。
- git push 仓库链接(https/ssh) 分支名:推送到远程仓库。
- git pull 仓库链接(https/ssh) 分支名:将github托管的代码拉取到本地。自动合并本地文件。
- git remote add 名称 远程仓库链接 : 给仓库起别名
- git remote -v:查看添加的远程仓库。
- git clone 仓库链接 分支名:克隆远程仓库到本地
- git fetch 仓库链接 分支名:拉去远程仓库,但不合并。
- git merge 仓库链接 分支名:合并仓库
- 生成ssh公钥: ssh-keygen