How to diagnose and fix git fatal: unable to read tree

前端 未结 5 920
误落风尘
误落风尘 2020-11-30 03:06

I\'m using git to manage files on a project, and keep running into this problem.

When I run git status I get the message

fa         


        
5条回答
  •  误落风尘
    2020-11-30 03:25

    Following my older recommendation, it boils down to being able to find a repo which actually contains the missing elements (here full trees).
    This is what is shown in "How to fix corrupted git repository?".

    But if a full clone doesn't solve the problem, then it may be:

    • a corruption of the repo on the GitHub side (contact GitHub support to check).
    • some kind of corruption on the client side (your Ubuntu). Make sure to check if the issue persists with the latest Git release (1.8.5.2-1) from a custom PPA (Personal Package Archive).

    Update July 2016, with Git 2.10 soon to be release, you now have:

    git fsck --name-objects
    

    See "How to fix git error broken link from tree to tree?" for more.

提交回复
热议问题