git遇到过的错误

来源:互联网 发布:车行168 php笔试题 编辑:程序博客网 时间:2024/05/14 20:23

用git也是走了很多弯路。
比如:
这种错误
1.

$ git commit -afatal: Unable to create 'E:/****/.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 processesare terminated then try again. If it still fails, a git processmay have crashed in this repository earlier:remove the file manually to continue.

解决方法:
使用了$ rm -f ./.git/index.lock

然后我估计是点击了编辑,就出现了这个鬼

<****.github.io/.git/COMMIT_EDITMSG[+][RO] [unix] (18:21 22/07/2016)1,0-1 All

输入:wq!(千万要记住!要加上去,万恶的电脑,少个符号都识别不了,这就是为什么我喜欢人脑)
然后就正常了
还有这种错误:
2.
这里写图片描述

出现这个问题是因为,没有在github账号添加SSH key,
为了方便,我用了HTTPS协议

0 0
原创粉丝点击