Another git process seems to be running in this repository

后端 未结 28 2201
梦谈多话
梦谈多话 2020-11-29 14:34

I\'m trying to learn how to use Git and have created a small project with an HTML, CSS, and Javascript file. I made a branch from my basically empty project and then made so

相关标签:
28条回答
  • 2020-11-29 15:07

    Try deleting index.lock file in your .git directory.

    rm -f .git/index.lock

    Such problems generally occur when you execute two git commands simultaneously; maybe one from the command prompt and one from an IDE.

    0 讨论(0)
  • 2020-11-29 15:08

    This happened to me and while sourcetree kept telling me the lock file exists, there was no such a file there for me to remove. So I just checked out another branch and then returned to the original branch and noticed this change fixed the issue.

    0 讨论(0)
  • 2020-11-29 15:08

    Solved it by going into the .git folder and manually deleting the HEAD.lock file

    0 讨论(0)
  • 2020-11-29 15:09

    If you are using CocoaPods and at some point botched an update or install (manually killed it or something), try

    1) Removing the index.lock file (in .git/index.lock)

    2) Remove your Podfile.lock file.

    3) Do a new pod update

    4) Try issuing the git command that was failing (in my case it was a git add .)

    0 讨论(0)
提交回复
热议问题