标签:str origin 实现 使用 check .sh pst team master
git remote add upstream https://github.com/studygolang/GCTT
添加fork项目的远程仓库(只需操作一次)
此时使用
git remote -v
zuoguoyaodeMacBook-Pro:GCTT zuoguoyao$ git remote -v
origin https://github.com/zuoguoyao/GCTT.git (fetch)
origin https://github.com/zuoguoyao/GCTT.git (push)
upstream https://github.com/studygolang/GCTT.git (fetch)
upstream https://github.com/studygolang/GCTT.git (push)
git fetch upstream
获取上游改动
git checkout master
转到master分支
git rebase upstream/master
合并分支,结果等同于merge.git实现的机制不一样
参考下文
http://gitbook.liuhui998.com/4_2.html
git push -f origin master
强制(-f )覆盖远程 origin仓库的master分支
GCTT(Go Chinese Translation Team) sync.sh同步命令详解
标签:str origin 实现 使用 check .sh pst team master
原文地址:https://www.cnblogs.com/fudianheg/p/10225981.html