git non-fast-forward error [duplicate]
I've reverted to a previous version of my commit then I've done some other commits but without pushing to the remote repo.
When I do push I got the following er开发者_开发技巧ror:
To git@xxxxxx ! [rejected] REPO -> REPO (non-fast-forward) error: failed to push some refs to '.....' 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.
Yet, when I do a pull, I get repo up to date. Please help, I cannot integrate my work.
git push --force
"Usually, the command refuses to update a remote ref that is not an ancestor of the local ref used to overwrite it. This flag disables the check. This can cause the remote repository to lose commits; use it with care."
精彩评论