Git pull remote branch and merge to local
git fetch pull remote branch does not do merge ignore file. Gitignore Add file git Add. Commit all modifications git commit-am ' memo info ' push local branch to warehouse GIT push origin master:master Delete remote Branch git push origin:test from the remote code to the local repository Git pull Origin master:master create a new branch based on the branch git checkout-b dev2 master switch branch git checkout dev2 Delete Except local branch git branch-d dev2 Force Delete local branch git branch-d dev2 View all branches git branch-a view all remote branches git branch-r Delete local presence remote nonexistent git branch-d-R Origin/test pull the remote branch to local GIT fetch Origin dev pull the remote and merge local Git pulls Origin dev there may be conflicting staging modification records git stash (can save add file add warehouse together) view staging record Git Stash list Delete staged Git stash drop staging number clear staged git stash clear pop-up staged git stash pop undo uncommitted modify Git checkout filename undo committed modify Git Reset–h Ard|–soft version undo push modified Git revert-n commitid (resolve conflict, commit, push)
Common git operations