eclipse errors when try to change to master git branch

7k Views Asked by At

When I try to switch to the master branch in eclipse, I get an error:

Branch failed Cannot lock /home/pal/workspace/pal-prod/.git/index

Any ideas what causes this? I'm having trouble searching for that error (nothing similar came up).

I'm not sure if my VM has size issues, or why it can't lock that.

I am currently in branch Bom. Eclipse says pal-prod [pal-prod Bom up arror 2] in the Project Explorer. I recently pushed changes through the linux command line since I have been having error messages in eclipse when I try to push, commit, etc.

Thanks, Mich

1

There are 1 best solutions below

2
On BEST ANSWER

Read this issue and try the solution if the problem description is the same as your :

Solution is to delete index.lock if it exist (when eclipse is shutdown and no other process interact with the repo)

.lock files are created when a process use the repository, so my guess would be that a .lock file wasn't deleted properly and Egit still think it's busy.