Post date: Jan 18, 2016 8:28:08 PM
I ran "brew update" and received the error message "fails with: fatal: git-write-tree: error building trees ..." The issue is resolved by the following steps:
/usr/local and run brew command> brew update> brew upgrade> brew install your_packageHere is what I tried on my terminal
> git reset --hard origin/master; git checkout --force master> cd /usr/local/> git statusOn branch masterUnmerged paths: (use "git reset HEAD <file>..." to unstage) (use "git add <file>..." to mark resolution)both modified: Library/Formula/python.rb
no changes added to commit (use "git add" and/or "git commit -a")> git reset --hard origin/master; git checkout --force masterHEAD is now at ef28579 ipfs: update 0.3.10 bottle.Already on 'master'> git statusOn branch masternothing to commit, working directory clean> brew update> brew upgrade> brew install <whatever_package>