I am in the process of migrating from Subversion to Git for all of my projects and needed a way to install the latest version of Git in Ubuntu. There are many excellent resources that I have combined in this howto. I will be installing Git from Launchpad.
The first step in installing the latest version of Git is to tell apt where and how to get Git. These instructions are for Ubuntu Hardy Heron 8.04 LTS and will also work on later versions. Note that since Ubuntu 9.10 you can use the "sudo add-apt-repository" method to add the latest version of Git to Ubuntu. Create "/etc/apt/sources.list.d/git.ppa.list" and add the following lines (note that you can skip the deb-src if you do not need the Git source):
To use this approach to install the latest Git for other versions of Ubuntu simply change "hardy" to the appropriate name (eg: lucid, karmic, jaunty, or intrepid).
Note that if you were to run "sudo apt-get update" you will get the following error:
To remove this message Ubuntu must be told that the package repository can be trusted. Go to the Launchpad PPA for Smartlounge and click on the "Technical details about this PPA". Note the signing key; in this case it is listed as "1024R/643C34E6". Copy the last part of the key and run the following command:
You should see the following message:
And now you can install the latest version of Git for Ubuntu:
Launchpad PPA for Smartlounge also maintains the following packages:
Comments
Post new comment