How to upgrade Git on Ubuntu? [duplicate]
If you want the latest git on your system, add this ppa in your software sources. Then install git-core if it wasn't done before, and update your system.
However I would suggest to upgrade to an unsupported package only if you require some specific features included only in the latest version.
sudo apt-get update
sudo apt-get upgrade
If you already have it installed and everything is clean.
If you want the absolute newest version and that is not in the repositories, there is a guide to doing that here: http://ropiku.wordpress.com/2008/04/14/updating-git-on-ubuntu/
Just to summarize:
sudo add-apt-repository ppa:git-core/ppa
sudo apt-get update
sudo apt-get upgrade