Simply restarting the computer helped in this scenario for me. I didn't have an index.lock file in .git folder.