I did a Git pull when I was near my quota, and as a result (so I think), got a corrupted file:
$ git pull
walk dffbfa18916a9db95ef8fafc6d7d769c29a445aa
fatal: object d4a0e7599494bfee2b5351113895b43c351496b3 is corrupted
$ git fsck --full
bad sha1 file: .git/objects/66/b55c76947b1d38983e0944f1e6388c86f07a1b.temp
fatal: object d4a0e7599494bfee2b5351113895b43c351496b3 is corrupted
$ git cat-file -t d4a0e7599494bfee2b5351113895b43c351496b3
error: unable to find d4a0e7599494bfee2b5351113895b43c351496b3
fatal: git cat-file d4a0e7599494bfee2b5351113895b43c351496b3: bad file
How can I solve this corruption?
.git/objects/66/b55c76947b1d38983e0944f1e6388c86f07a1b.temp was zero bytes; deleting it did nothing to solve my problem (same errors).
find . -name d4a0e7599494bfee2b5351113895b43c351496b3
is nothing. Deleting the sha1 file then pulling just results in the empty sha1 file being generated. – Richmond$ git cat-file -t d4a0e7599494bfee2b5351113895b43c351496b3's
output is:error: unable to find d4a0e7599494bfee2b5351113895b43c351496b3 fatal: git cat-file d4a0e7599494bfee2b5351113895b43c351496b3: bad file
– Richmond.git/objects/d4/a0e7599...
. You could try backing up and removing that object (and removing any associated temporary files) and pulling again. – Anomieerror: Entry 'myFile.h' not uptodate. Cannot merge. fatal: merging of trees c088e794c4820171e75f829957f7c402b228aaa7 and 66b55c76947b1d38983e0944f1e6388c86f07a1b failed
– Richmondgit reset
to get your index back into a good state? – Anomiegit stash ; git pull ; git stash pop
did the trick. – Richmond