git中常混淆的操作

1, git fetch 和 git pull

参考链接: https://stackoverflow.com/questions/292357/what-is-the-difference-between-git-pull-and-git-fetch

git pull = git fetch + git merge;

git fetch 从远程分支取下最新的代码,但不会影响本地分支代码

git pull  从远程分支拉下最新代码,并和自己的本地分支做融合操作。更新了本地分支。

2, git rebase 和 git merge

https://blog.csdn.net/wh_19910525/article/details/7554489

猜你喜欢

转载自www.cnblogs.com/hiluna/p/9291844.html