$ git branch
master
* portal
$ git fetch
$ git merge origin/portal
Already up-to-date.
$ git pull
Already up-to-date.
$ git push
To [email protected]:ripper234/Commerce-Sciences.git
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to '[email protected]:ripper234/Commerce-Sciences.git'
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes (e.g. 'git pull') before pushing again. See the
'Note about fast-forwards' section of 'git push --help' for details.
通常我会做一个gitk -all
来试试看看到底发生了什么,但是这是在没有图形化外壳的Linux机器上。为什么我的推送被我拒绝后拒绝?
[推送操作抱怨非快进,即使远程一直拖着]的可能重复(http://stackoverflow.com/questions/5723714/git-push-complaining-about - 非快进 - 即使 - 尽管远程 - 已被拉) – ripper234 2012-01-16 09:55:22
一个方便的终端,唯一替代'gitk --all'是'git log --oneline --graph --decorate --all' – 2012-01-16 10:06:00