Skip to content

Instantly share code, notes, and snippets.

@rcmachado
Created March 28, 2013 14:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rcmachado/5263788 to your computer and use it in GitHub Desktop.
Save rcmachado/5263788 to your computer and use it in GitHub Desktop.
How to install most recent git using homebrew
# install brew if not installed
which brew > /dev/null || ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go)"
# update brew package list
brew update
# install git from brew
[[ -x /usr/local/bin/git ]] || brew install git
# if git is installed, upgrade it
brew upgrade git
# Ensure /usr/local/bin is before anything else on your path
echo 'export PATH=/usr/local/bin:$PATH' >> ~/.bash_profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment