Another git process seems to be running in this repository
git add . 报错
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.
原因:git被另外一个程序占用,重启机器也不能够解决。
原因在于Git在使用过程中遭遇了奔溃,部分被上锁资源没有被释放导致的。
解决方案:
进入项目文件夹下的 .git文件中【删除index.lock文件】,如若看不到该文件,需要显示隐藏文件夹。或者直接执行 【rm .git/index.lock】
注【显示文件夹
defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder
隐藏文件见
defaults write com.apple.finder AppleShowAllFiles -boolean false ; killall Finder】
相关推荐
formula 2020-11-12
huhongfei 2020-11-05
乾坤一碼農 2020-10-27
liumengyanysu 2020-10-22
E哥的aws认证攻略 2020-10-15
tianyafengxin 2020-10-08
guying 2020-10-05
好脑筋不如烂笔头 2020-09-17
nebulali 2020-09-11
佛系程序员J 2020-09-15
fenggit 2020-09-15
JustHaveTry 2020-09-11
兄dei努力赚钱吧 2020-09-06
IngeniousIT 2020-08-25
liumengyanysu 2020-08-17
guying 2020-08-16