Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Source Tree Error Please Help

Gabriel Smith June 20, 2014

fatal: Unable to create 'C:/Users/Jon/Documents/DoomCarts/.git/index.lock': File exists.

If no other git process is currently running, this probably means a

git process crashed in this repository earlier. Make sure no other git

process is running and remove the file manually to continue.

How can we commit?

4 answers

3 votes
HenriqueA
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 21, 2014

Hi Dfg,

If you're not running other GIT process, just delete the C:/Users/Jon/Documents/DoomCarts/.git/index.lock file and try again.

Kind Regards,
Henrique Lechner

Seth
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 22, 2014

Correct. Which is what the error message is telling you to do.

Seth
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 22, 2014

If you can't find the .git folder, you may need to change your Windows File Explorer options to show hidden folders, or type the path directly into your address bar.

2 votes
André Neves September 29, 2016

This is a known bug: https://jira.atlassian.com/browse/SRCTREEWIN-5639

You should open that bug and vote for it, to give it more priority.

 

As a work-around, use the solution proposed by Henrique Lechner:

If you're not running other GIT process, just delete the C:/Users/Jon/Documents/DoomCarts/.git/index.lock file and try again.

2 votes
johankronberg September 18, 2016

I get this a lot when switching branch. Sometimes it's enough to just wait a couple of seconds and then try again. Other times I need to Exit SourceTree and start it up again before being able to switch branch.

0 votes
Alex Sedighi December 21, 2017

This happened to me and while sourcetree kept telling me the lock file existed, 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.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events