How to install homebrew in OS X Mountain Lion

Standard

Homebrew aka brew aka The missing package manager for OS X is a package management system that simplifies the installation of free software programs on OS X.

Installation in Mountain Lion is a bit different from previous OS X versions, here are the steps to do it (taken from this gist]:

  • Install last XCode from the App Store.
  • launch XCode. You don't need to create any project, just go to XCode > Preferences > Downloads and install Command Line Tools (about 110MB).
  • Change the path of the XCode folder: sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
  • X11 libs are needed for some brew-installable programs, so download and install last version from XQuartz's website.
  • Fix its symbolic link: ln -s /opt/X11 /usr/X11
  • If you don't want to use sudo to install programs with homebrew (you can read why in the FAQ) you need to change /usr/local/ permissions: sudo chown -R $USER /usr/local
  • Finally you can install homebrew: ruby <(curl -fsSkL raw.github.com/mxcl/homebrew/go)
  • Here are some programs that i usually install: brew install coreutils wget wput colordiff ctags highlight bar xmlformat rename ack dos2unix csshX imagemagick links unrar gnu-tar fasd

One thought on “How to install homebrew in OS X Mountain Lion

Leave a Reply

Your email address will not be published. Required fields are marked *