Error in deleting/addind file from appharbor using git “Unable to create 'f:/git/xyz/WorkerProcess/.git/index.lock': File exists”

元气小坏坏 提交于 2019-12-04 05:50:05

问题


I want delete bin[or trying to run $git add .] from local git hub folder as well as on hosted app-harbor folder but i am unable to delete folder and getting following error

 $ git rm -r bin [ $ git rm -f bin]
 fatal: Unable to create 'f:/git/xyz/WorkerProcess/.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.

回答1:


It works for me :

$ git clean -f  .git/index.lock
Removing .git/index.lock
comp1@SHAILESH01 /f/git/xyz/WorkerProcess (master)
$ git init
Reinitialized existing Git repository in f:/git/xyz/WorkerProcess/.git/
comp1@SHAILESH01 /f/git/xyz/WorkerProcess (master)
$ git add .
comp1@SHAILESH01 /f/git/xyz/WorkerProcess (master)
$ git rm  bin
fatal: not removing 'bin' recursively without -r
comp1@SHAILESH01 /f/git/xyz/WorkerProcess (master)
$ git rm -r -f bin


来源:https://stackoverflow.com/questions/17916339/error-in-deleting-addind-file-from-appharbor-using-git-unable-to-create-f-git

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!