Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Brew update error [closed]

Tags:

homebrew

I am using a macbook and have ruby installed on my machine. I wanted to install a ruby gem but wanted to update HomeBrew first. I ran 'brew update' in my home folder and got this error:

 error: The following untracked working tree files would be overwritten by merge:
Library/Formula/vcprompt.rb
 Please move or remove them before you can merge.
 Aborting
 Error: Failure while executing: git pull -q origin refs/heads/master:refs/remotes/origin/master

I tried going in to the library/formula folder but it doesn't exist on my machine. I am not sure what to do from here.

like image 429
andy4thehuynh Avatar asked Mar 28 '13 22:03

andy4thehuynh


1 Answers

cd /usr/local && git reset --hard FETCH_HEAD

or if it fails

cd /usr/local && sudo git reset --hard FETCH_HEAD

like image 130
pid Avatar answered Sep 21 '22 08:09

pid