index file smaller than expected

前端 未结 3 1043
滥情空心
滥情空心 2021-02-01 00:25

This morning, I started getting this error from git:

fatal: index file smaller than expected

fatal: git status --porcelain failed

3条回答
  •  遇见更好的自我
    2021-02-01 00:56

    The index file has become corrupted, but it is easily re-creatable. Just remove it...

    rm .git/index
    

    Then you can re-add the files you're trying to stage.

提交回复
热议问题