github项目提交失败 master -> master (non-fast-forward)

提交项目的时候出现这个问题:

官方介绍:

https://help.github.com/articles/dealing-with-non-fast-forward-errors

我的解决方法是:

参考:

http://stackoverflow.com/questions/9661059/git-pull-rebase-upstream-git-push-origin-rejects-non-fast-forward

先执行git pull

然后再执行 git push --force origin master 替换原先的git push -u origin master

猜你喜欢

转载自michaelye1988.iteye.com/blog/1653599