git error: bad signature fatal: index file corrupt 解决方案

问题

写好代码准备使用 git desktop 提交的时候,发现我的项目提示 can’t find XXX (XXX 为项目名),并且使用 git bash 输入:git pull 会提示:

error: bad signature 
fatal: index file corrupt

然后尝试remove掉我的项目,重新 Add Repositories, 也无法识别我的本地项目

解决方案:

步骤1

项目根目录下打开 git bash ,输入:

rm -f .git/index

步骤2

接着输入:

git reset

参考自: https://dushusir.com/git-error-bad-signature-fatal-index-file-corrupt, 感谢!

1人评论了“git error: bad signature fatal: index file corrupt 解决方案”

  1. Pingback: git error: bad signature fatal: index file corrupt 解决方案 - 独书先生

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注