So at work we all share the same stash were we push and pull our branches and all that good git stuff. So i usually do my pull and push from egit in eclipse (I am not the only one most people here do it this way). but some of my branches have started giving me the [lock fail] "couldn't lock local tracking ref for update". But the thing is there are 75+ people doing it the same way and no one has seen this error. I have done some research and most of it says it is based off name conflicts for example Foo and foo. Egit would get confused on which one to pull because the only difference is a capital letter, but other people are having no issues. I don't know what is going on. Any help would be greatly appreciated.
Eclipse EGit™ EGit is an Eclipse Team provider for the Git version control system. Git is a distributed SCM, which means every developer has a full copy of all history of every revision of the code, making queries against the history very fast and versatile.
I could neither fetch nor push nor rebase, and got a "lock fail" error in eclipse too.
The solution I found was to open git bash, go to git folder, then do a git fetch
. After this I was able to rebase and push with eclipse.
You can also check in your eclipse preferences/team/git/configuration that you have not set fetch.prune=true
because it may cause this problem.
git remote prune origin
solved it for me.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With