我似乎有一个损坏的回购,我不知道如何修复...
$ git pull
remote: Counting objects: 141, done.
remote: Compressing objects: 100% (90/90), done.
error: unable to unpack ff7fca002656ad848c44bf134088d638a01d5217 header
error: inflateEnd: stream consistency error (no message)
fatal: SHA1 COLLISION FOUND WITH ff7fca002656ad848c44bf134088d638a01d5217 !
fatal: index-pack failed
Unable to write to standard output: The pipe is being closed.
这是fsck
的输出
$ git fsck
error: unable to unpack 024e257c1a13532e7d5579b0ea4bb5915d21e4a6 header
error: inflateEnd: stream consistency error (no message)
fatal: loose object 024e257c1a13532e7d5579b0ea4bb5915d21e4a6 (stored in super/sectet/path/to/repo/.git/objects/02/4e257c1a13532e7d5579b0ea4bb5915d21e4a6) is corrupt
你有什么想法来解决这个问题吗?我基本上想要得到遥控器中的任何东西,并在此之上推送我的几个提交。
发布于 2014-06-01 18:43:54
我认为存储库被EGit或SourceTree (我并行使用)损坏了,实际上与散列冲突无关。正如评论所建议的那样,我通过克隆遥控器作为新的存储库,并复制我的更改来解决它。
发布于 2017-02-01 12:08:04
我有一个类似的问题,并通过运行以下命令解决了它:
$ git prune
Output: fatal: unable to parse object: refs/heads/prod-283
只需删除上面的引用:
$ rm -f .git/refs/heads/prod-283
我终于可以运行git pull
了
发布于 2018-07-06 14:44:08
我运行了以下commnads:
git prune
git gc
并删除了文件.git\refs\remotes\origin\master (在错误:错误引用中列出的文件)
和范围
git gc --prune=now
解决了这个问题。
https://stackoverflow.com/questions/23964033
复制相似问题