fatal: git-write-tree: error building trees

Short answer: Try resolving any merge conflicts, committing them, and they fetch/pull again.

Longer explanation: I'm guessing you resolved this issue, since it was posted so long ago. I'm writing this since Google's ranking of StackOverflow articles is high enough that other people with this problem would be very likely to visit this page if they had this error.

I encountered a similar error when trying to do a "git stash", what turned out to be the problem was that a merge conflict had occurred after a pull. I had not resolved & committed the conflict, and this left the repository in a state that prevented me from pulling/merging/etc...

If you make sure you don't have any blocking files, try again.

Good luck!


git svn gc

(possibly git gc and git prune before)

Tags:

Git