

Every time I quit the terminal and restarted it, when I typed git -version the terminal, it still return the older version 1.8. I updated my terminal path by using the above mention export command. Nice! We’re safe now! And next time you can just…Īfter searching for "trouble upgrading git on mac" on Google, I read several posts and attempted the following before resolving the problem by completing step 4:

Quit terminal and open a new terminal, then check version. $ sudo mv /usr/bin/git /usr/bin/git-apple IF YOU DON'T HAVE HOMEBREW, FOLLOW THESE STEPS If however you still see apple version, then type the following two lines, which will manually set our path to the local git distro instead of the Apple one.

If the output of the above command shows the latest version and does not mention Apple with the version details, then you are all set. This should automatically install git and set it in your path, replacing the Apple one. It's simple if you already have Homebrew:Īssuming you have homebrew installed, type the following: brew install git
