git提交时报错:Updates were rejected because the tip of your current branch is behind
遇到这个问题别慌,这个说明你当前的分支代码不是最新的代码,你需要去更新一下master分支
- push前先将远程repository修改pull下来
git checkout master
git pull origin master
git push -u origin master
- 然后checkout 出你的分支 假定叫 AA
git checkout AA
git merge master
- 完事之后,你就可以push了
git add .
git push origin master
放一张去年的照片压压惊~