git push merge error, but git pull is already up-to-date. Tried reclone, same problem

后端 未结 5 1392
臣服心动
臣服心动 2021-02-10 03:37

I do:

$ git commit .
$ git push
error: Entry \'file.php\' not uptodate. Cannot merge.

Then I do

$ git pull
Already up-to-date.
         


        
5条回答
  •  别跟我提以往
    2021-02-10 04:40

    Try doing a git checkout file.php then git push again.

    Update:

    • git pull tells the branch is up-to-date?
    • git status doesn't show any unmerged file?
    • git commit works?

    If you answered yes to all above, and your git push keeps failing even after a clean copy of the remote repository (read git clone), it's very likely the remote repository has an index problem.

提交回复
热议问题