When trying to git push my changes on git, I get the following error:
To $gitRepo
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to $gitRepo
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes (e.g. 'git pull') before pushing again.
No modifications have been made on this branch (I'm the only one working on it). So I really shouldn't get a non-fast-forward error.
When I do git pull, I get:
You asked me to pull without telling me which branch you
want to merge with, and 'branch.$myCurrentBranch.merge' in
your configuration file does not tell me, either. Please
specify which branch you want to use on the command line and
try again (e.g. 'git pull <repository> <refspec>').
See git-pull(1) for details.
I am indeed on $myCurrentBranch, as git status confirms it.
Funnily enough, the changes are registered (checked both with git log and on the repository).
Do you have any ideas why I get these errors?