在使用TortoiseGit提交程序时出现以下错误提示:
git.exe add -f [...]
fatal: Unable to create 'Z:/WPQ3000D/.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.
根据网上的提示将index.lock文件删除,但是我删除后再次提交后又出现了下面的新问题:
git.exe update-index [...]
fatal: Unable to write new index file
出现这个问题是TortoiseGit操作我.git文件夹中的文件时权限不够导致的,由于我工程文件是放在Ubuntu中的,并将其映射到Windows下,所以就出现了这个权限的问题。
将.git文件夹下的文件使用chmod 777 来修改权限后问题解决。