Tuesday, July 9, 2019

software installation - How do I install the latest version of Git with apt?


I read about a security flaw in Git, which was fixed in version 2.2.1. I currently have Git 2.1.0 on my system (Ubuntu 14.10), and tried to reinstall it with apt. However, apt told me that I currently have the latest version.


The Git website does not have prebuilt versions for Linux. They say that you can install it with package managers. Without building from source, how would I install the latest version of Git?



Use the PPA from the maintainers of git on Ubuntu:


sudo apt-add-repository ppa:git-core/ppa
sudo apt-get update
sudo apt-get install git

If you don't know what PPAs are, first read What are PPAs and how do I use them?


If you receive an error about add-apt-repository command not found you may need to add the python-software-properties package or software-properties-common depending on your Ubuntu version.


Ubuntu 14.04


sudo apt-get install software-properties-common

Ubuntu 13.10 or earlier


sudo apt-get install python-software-properties

No comments:

Post a Comment

11.10 - Can't boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...