Install Git on Mac OS X 10.7 Lion

  1. Download the latest version of Git from the Git Project Home
    1. If there is no specific version for Lion, the version for Snow Leopard works just fine.
  2. Open the .dmg file you downloaded
  3. Run the package
  4. Restart your computer

10 thoughts on “Install Git on Mac OS X 10.7 Lion

  1. Nice and simple. But not complete. :)

    May I suggest: Step 4 isn’t necessary I believe.

    After step 3 we should look into to see our git:


    you’ll need to either add it to your $PATH or make a symlink placing the binary inside a directory that is in your existing PATH.

    A common practice is to make /usr/local/bin if it doesn’t exist and add a link:

    sudo -s
    mkdir -p /usr/local/bin
    ln -s /usr/local/git/bin/git /usr/local/bin/git

    then, restart the terminal.

    We can now type git from our command line.

  2. Thank you for your comment.

    The Mac OS X Snow Leopard git installer handles the copying of files and $PATH variables without any issue. If a user would like to verify that it was installed to the right directory, they can check in /usr/local/git.

    I suggested the restart in order to ensure the $PATH variable is populated system-wide, and not for the user terminal session only.

  3. Guys, I want to thank you very much for this solution! I am new to all this stuff and after dragging through endless sites, your explanation was concise and clear, AND it worked!! Thanks!!

  4. Pingback: Git For Lion
  5. It’s a bit of an old post, but git resides under /usr/local that is not in your path in OS X Lion. Just add it :

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

    Then :

    source ~/.bash_profile

  6. I have a problem on installing git on mac os x lion. I got a error indicating “no mountable file system” error. can anyone suggest how to fix this errors.

  7. Thanks you guys, I am very new to Mac os X just bought it few days back and I was struggling like anything to find out how to have git command from terminal. It nicely worked from me, use any package from google code project download and install and restart terminal it work like charm, no need of anything it does everything by itself, but if in any case it does allow you to use git from from terminal than they also provide .sh to set path just run it from terminal

Leave a Reply

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

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>