当前位置:   article > 正文

Another git process seems to be running in this repository, e.g. an editor opened by ‘git commit‘._n editor opened by 'git commit'. please make sure

n editor opened by 'git commit'. please make sure all processes are terminat

问题描述:

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 commit”指令,请关闭所有git相关的进程重试,否则,请手动删除那个文件。
windows对于进程的同步互斥管理,是有资源上锁机制的。猜测这里肯定是有进程对某资源进行了加锁,但是由于进程突然崩溃,未来得及解锁,导致其他进程访问不了。


解决方案:

进入工作区目录下的隐藏文件.git,其中的index.lock文件删除掉,然后重新打开git bash进程,问题解决。

在这里插入图片描述

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/知新_RL/article/detail/826745
推荐阅读
相关标签
  

闽ICP备14008679号