有时候在提交的时候,中间提交出错,导致有文件被lock,所以会报下面的错误:

fatal: Unable to create ‘/msg/.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

1、命令行代码   rm -f ./msg/.git/index.lock

2、直接去文件系统进行删除该lock文件

Git – fatal: Unable to create ‘/.git/index.lock’: File exists错误解决办法的更多相关文章

  1. Git添加本地项目出现fatal: unable to get credential storage lock: File exists

    把本地项目初始化之后上传到github上出现问题:fatal: unable to get credential storage lock: File exists 解决办法:是因为我上传用的git帐 ...

  2. create ‘/.git/index.lock’: File exists.

    Git – fatal: Unable to create ‘/.git/index.lock’: File exists. fatal: Unable to create ‘/path/my_pro ...

  3. EXCEPTION:FATAL: UNABLE TO CREATE ‘…GIT/INDEX.LOCK’ FILE EXISTS

    FATAL: UNABLE TO CREATE ‘…GIT/INDEX.LOCK’ FILE EXISTS Hi, Today I will share you my other experience ...

  4. git提交代码出现错误fatal: Unable to create '项目路径/.git/index.lock': File exists.

    git提交代码出现错误fatal: Unable to create '项目路径/.git/index.lock': File exists. 具体出错代码如下: 具体原因不详,在stackoverf ...

  5. git提交代码报:fatal: Unable to create 'E:/testGit/test/.git/index.lock': File exists.

    git提交代码报错,提示:fatal: Unable to create 'E:/testGit/test/.git/index.lock': File exists. 具体截图如下: 在.git目录 ...

  6. Git本地仓库与远程github同步的时候提示fatal: remote origin already exists 错误解决办法

    Git本地仓库与远程github同步的时候提示fatal: remote origin already exists 错误解决办法 1.git在本地的电脑创建了仓库,要远程同步github的仓库.使用 ...

  7. git error: unable to write file xxx,git fatal: unable to write new index file

    执行git checkout -- . error: unable to write file mobile/manifest.jsonfatal: unable to write new index ...

  8. 记一次git fatal: Unable to find remote helper for 'https'问题的解决

    登陆到远程linux服务器上,使用git, clone的时候报“fatal: Unable to find remote helper for 'https'”错,没管,绕过,使用git clone ...

  9. Git 提示fatal: remote origin already exists 错误解决办法

    今天使用git 添加远程github仓库的时候提示错误:fatal: remote origin already exists. 最后找到解决办法如下: 1.先删除远程 Git 仓库 $ git re ...

随机推荐

  1. oracle安装心得

    1.官网下载 oracle 11g r2 2.官网下载的oracle包括两个文件夹file1和file2,需要将解压后的file2中的stage-components文件夹下的内容复制到file1-s ...

  2. servlet 生命周期

    Ò编写一个HelloWordServlet类

  3. Unity多线程(Thread)和主线程(MainThread)交互使用类——Loom工具分享

    Unity多线程(Thread)和主线程(MainThread)交互使用类——Loom工具分享 By D.S.Qiu 尊重他人的劳动,支持原创,转载请注明出处:http.dsqiu.iteye.com ...

  4. eclips android项目复制

    1.将要复制的项目从workspace里面copy到另外一个目录 2.将这个项目重命名 3.使用android tool 里的包名修改工具(rename appliction package),修改报 ...

  5. SpringMVC配置入門

    我的開發環境 開發工具:    springsource-tool-suite-2.9.0 JDK版本:    1.6.0_29 tomcat版本:apache-tomcat-7.0.26 本文地址: ...

  6. Python3学习(1)-基础篇

    Python3学习(1)-基础篇 Python3学习(2)-中级篇 Python3学习(3)-高级篇 安装(MAC) 直接运行: brew install python3 输入:python3 --v ...

  7. EmberJs之使用Ember-Data

    写在前面 最近比较忙,换了新工作还要学习很多全新的技术栈,并给自己找了很多借口来不去坚持写博客.常常具有讽刺意味的是,更多剩下的时间并没有利用而更多的是白白浪费,也许这就是青春吧,挥霍吧,这不是我想要 ...

  8. VS中自定义代码高亮

    文章:http://www.cnblogs.com/aanbpsd/p/Viola_ide_glslEditor.html 帮助: 编辑扩展点: https://msdn.microsoft.com/ ...

  9. windows下重启mysql

    其中第二种方法对我这无效,以后再搞清楚! 一.MYSQL服务 我的电脑——(右键)管理——服务与应用程序——服务——MYSQL——开启(停止.重启动) 二.命令行方式 Windows 1.点击“开始” ...

  10. AJAX跨域调用相关知识-CORS和JSONP(引)

    AJAX跨域调用相关知识-CORS和JSONP 1.什么是跨域 跨域问题产生的原因,是由于浏览器的安全机制,JS只能访问与所在页面同一个域(相同协议.域名.端口)的内容. 但是我们项目开发过程中,经常 ...