0

Trying to update homebrew, I get this:

$ brew update

error: Your local changes to the following files would be overwritten by merge:
    .gitignore
    Library/Contributions/brew_bash_completion.sh
    Library/Contributions/brew_fish_completion.fish
    Library/Contributions/brew_zsh_completion.zsh
    Library/Contributions/manpages/brew.1.md
    Library/ENV/4.3/cc
    Library/ENV/4.3/make
    Library/ENV/4.3/xcrun
    Library/ENV/libsuperenv.rb
Please, commit your changes or stash them before you can merge.
error: The following untracked working tree files would be overwritten by merge:
    CONTRIBUTING.md
    Library/Aliases/ag
    Library/Aliases/heroku

... etc...

Any way to just clean that up? Looks like it's using git under the hood?

1 Answer 1

1

That would depend on whether you care about local changes to those files. Did you change them yourself, or did you run a program that changed them, or something else?

If you didn't mean to change them at all, cd /usr/local and run git reset --hard HEAD; this will reset them all to their original state. Then try updating Homebrew.

2
  • I didn't change them intentionally. I have no idea what any of those files are even for! I'm wondering if they could have been changed by a previous aborted homebrew operation - does that sound plausible?
    – Peter Hall
    Mar 4, 2013 at 21:02
  • I definitely think that's plausible, but I think you should maybe raise this issue on the Homebrew GitHub page and see if they have a clear picture of what's going on here. Mar 4, 2013 at 23:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .