Those who do not use Homebrew as a package manager on OS X yet, you are missing a lot of fun and convenience. Check Homebrew out.
I'll take Git as an example.
Usually we do:
brew install git
to get the latest stable version (1.9.2, as of the time of writing this tip) of Git.
If you are brave enough to test an edge version, just add the
--HEAD parameter like this:
brew install --HEAD git
You'll get Git 2.0.0.rc2 as of the time of writing.
If you already have the stable Git installed, the above command will cause brew to complain. It's OK, just use
brew reinstall --HEAD git
And you'll be fine.
- The parameter
--HEADhas to be all capitalized, or brew will raise a complaint.
- You can run
brew cleanupto get rid of package leftovers.