昨晚用Git命令行提交代码add . 、commit -m""时终端崩溃了,再打开什么操作都做不了,报错信息如下:
fatal: Unable to create '/Users/estt/ckg/.git/index.lock': File exists.
Another git process seems to be running in this repository, e.g.
an editor opened by 'git commit'. Please make sure all processes
are terminated then try again. If it still fails, a git process
may have crashed in this repository earlier:
remove the file manually to continue.
第一句就能看出是被锁了然后/Users/estt/ckg/.git/index.lock已经存在,只需要到该路径下删除.lock文件问题解决