Install Homebrew (brew) on macOS

Nov 3, 2018 1 min read
Install Homebrew (brew) on macOS

What is it according to Wikipedia

Homebrew is a free and open-source software package management system that simplifies the installation of software on Apple's macOS operating system.

Install

Make sure that current user owns the sub directories, otherwise Homebrew will complain not having access to create the symlink.

sudo chown -R $(whoami) /usr/local/*

Install it:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  1. On ~/.bash_profile paste: export PATH=/usr/local/bin:$PATH
  2. Reload the changes: . ~/.bash_profile
  3. Try it out: brew install wget

That's it, all set!

Note: If you are using zsh, make sure you add that line to: .zshrc as well (it has to be at the very end).

Opting out of Analytics

Homebrew analytics helps maintainers and leaving it on is appreciated. However, if you want to opt out of Homebrew’s analytics, this will prevent analytics from ever being sent:

brew analytics off

How do I update my local packages?

First update the formulae and Homebrew itself:

brew update

You can now find out what is outdated with:

brew outdated

Upgrade everything with:

brew upgrade

Or upgrade a specific formula with:

brew upgrade <formula>

List all packages installed

brew list

How do I stop certain formulae from being updated?

To stop something from being updated/upgraded:

brew pin <formula>

To allow that formulae to update again:

brew unpin <formula>
Great! Next, complete checkout for full access to ArturoFM.
Welcome back! You've successfully signed in.
You've successfully subscribed to ArturoFM.
Success! Your account is fully activated, you now have access to all content.
Success! Your billing info has been updated.
Your billing was not updated.