How to upgrade Git (Mac OSX)

katopz
1 min readMay 8, 2016

--

https://octodex.github.com/privateinvestocat

Problem : Git vulnerabilities CVE-2016–2324 and 2315
Solution : Update it :)

Check version

$ git --version

Backup (or remove) Apple git (Optional)

$ sudo mv /usr/bin/git /usr/bin/git-apple

Install Homebrew if you didn’t have

$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Or update if you already have

$ brew update && brew upgrade

Install Git with Homebrew

$ brew install git

Symbolic link

$ brew link --force git

Close Terminal and reopen then check version

$ git --version

You should see…

git version 2.8.2

Nice! We’re safe now! And next time you can just…

$ brew update && brew upgrade

Happy Gitting!

--

--