问题描述
〜〜$ git commit。
错误:inflate:数据流错误(不正确的数据检查)
错误:损坏的松散对象'26f0654cde5d83f2ed8d971474d9d08a76644087'
致命:object 26f0654cde5d83f2ed8d971474d9d08a76644087已损坏
有问题的对象不存在,我一直在做提交每两天左右。
因为它不列出这个对象应该在哪里,我不知道它是怎么做的。
我想我最后一个是在上个月的30号,所以我已经很平衡了,但最近仍然我不知道为什么它现在正在做它正在做的事情。
我试过 git unpack-object -r< objectname
,它什么都不做。由于该对象不存在于我的硬盘上任何地方。
原始位现已更改:
Nom,我似乎刚刚找到它。我没有意识到,它实际上是26/26 /而不是自己。显然这个文件是在12月1日制作的,因为自上次外部备份以来我没有提到过这个对象,所以我相信是在几天之前。
最好的方法是什么? / p>
你需要看看这是什么对象。您需要确定它是否是blob,树,提交或(不太可能)签名或消息标记。
看看。
我会推荐做一个过滤分支或rebase -i --preserve-merges来清理记录历史,以便所有sha-1都可以解析为适当的对象。
~$ git commit .
error: inflate: data stream error (incorrect data check)
error: corrupt loose object '26f0654cde5d83f2ed8d971474d9d08a76644087'
fatal: object 26f0654cde5d83f2ed8d971474d9d08a76644087 is corrupted
The object in question doesn't exist and I've been doing commits every other day or so.
Since it doesn't list where this object supposedly is, I don't know what do with it.
I guess my last one was on teh 30th of last month, so I've been pretty off balance as of late but still I don't know why it's doing what it's doing right now.
I've tried git unpack-object -r < objectname
and it does nothing. Since the object doesn't exist ANYWHERE on my hdd.
The original bit is now changed:
Nom, I've seemed to have just found it. I didn't realize that it was literally doing 26 as /26/ instead of itself. Apparently the file was made on the 1st of December and since I don't have said object since the last external backup, I believe was a few days before.
What's the best way to go about this?
You will need to take a look at what object this is. You need to determine if it's a blob, tree, commit or (unlikely) a signed or messaged tag. Git has low level manipulation commands to do this.
Take a look at this post.
I would recommend doing a filter-branch or rebase -i --preserve-merges to clean up the history so all sha-1s resolve to proper objects.
这篇关于git有一个无法修复的损坏的丢失对象的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!