Git on Mac OS X v10.7 (Lion)

AnApprentice picture AnApprentice · Jul 25, 2011 · Viewed 110.4k times · Source

I just upgraded my Mac to Mac OS X v10.7 (Lion), and now Git is gone:

$ git
-bash: git: command not found

How can I get Git back?

Answer

Chris Ledet picture Chris Ledet · Jul 25, 2011

The default install location is /usr/local, so add this to your ~/.bash_profile file:

export PATH=$PATH:/usr/local/git/bin/

Then run source ~/.bash_profile in Terminal.