51

I have homebrew installed long before the OS is upgraded a few times to 10.12.3. Now that

$ brew --version
Homebrew 0.9.9 (git revision 080c; last commit 2016-08-11)
Homebrew/homebrew-core (git revision b163b; last commit 2016-08-10)

How to properly upgrade to newer version, say 1.1?

$ brew upgrade 

didn't work.

0

5 Answers 5

58

To update homebrew itself, use:

brew update

To upgrade all packages installed using homebrew, then you have to use brew upgrade. You can check this FAQ from brew website for more details.

0
17

The right way to solve this is to enter:

$ cd "$(brew --repo)" && git fetch && git reset --hard origin/master && brew update

Found at http://discourse.brew.sh/t/how-to-upgrade-brew-stuck-on-0-9-9/33.

0
5

As a habit, I run this command once a week:

brew update && brew upgrade && brew cleanup

It updates brew itself, casks and related packages then clears old package's unneeded files. Here is the result after running twice:

Already up-to-date
2

When you want to update Homebrew, use brew update. After running brew update, you may have outdated formulae installed, which is where brew upgrade is necessary.

$ git -C
Takes an existing commit object, and reuses the log messages and the authorship information (including the timestamp) when creating a commit.

/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core
This is the path to the homebrew-core folder on a computer.

fetch
Downloads objects and references from another repository.

--unshallow
This is a git fetch option. If the source repository is complete, it converts a shallow repository to a complete one, removing all the limitations imposed by shallow repositories.

brew update
Updates the Homebrew

0

Use these commands

$ git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow  
$ brew update
1
  • I think some explanation of what these commands do would be useful.
    – grg
    Jan 31, 2021 at 10:23

You must log in to answer this question.

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