1.Your branch is ahead of 'origin/master' by 2 commits
当本地提交时不是基于最新的代码地址,提交又rebase成功时,本地git pull会提示如上,可以使用下面的指令将本地指向最新的代码
git stash
git pull --rebase
git stash pop
2.撤销add操作
git reset HEAD
1.Your branch is ahead of 'origin/master' by 2 commits
当本地提交时不是基于最新的代码地址,提交又rebase成功时,本地git pull会提示如上,可以使用下面的指令将本地指向最新的代码
git stash
git pull --rebase
git stash pop
2.撤销add操作
git reset HEAD