How to fix the pushing rejected and asked to pull when pulling results in “everything is up to date”?

后端 未结 2 1594
一向
一向 2020-12-16 16:43

Using EGit with Eclipse when I try to push my code into the remote repository I get an error message saying that I should pull first, as shown in Figure 1.

2条回答
  •  猫巷女王i
    2020-12-16 17:15

    Make sure that:

    • you are using the latest version of EGit (2.3+)
    • you have stashed/commit everything before pulling (as in this thread)
    • you are not in a detached head mode (as in "can't push upstream using EGit")

    The OP Krige adds:

    in the end I noticed a class file was mentioned in the DIRTY_WORKTREE error message.
    I deleted that file from the file system, did a pull, resolved the conflicts and pushed.
    Everything seems to work fine now.

提交回复
热议问题