How to Install Git on Ubuntu 16.04

r00t December 15, 2017

Install Git on Ubuntu 16.04

In this tutorial we will show you how to install Git on Ubuntu 16.04. We will also install and configure its prerequisites. Git is a distributed version control program, which you can use to monitor the code varies (versions) while developing software. Git offers features such as reverting to a prior stage, multiple workflows, neighborhood branching and lots of others. This makes Git one of the best variant control systems and that is why it is used by many software developers.

I recommend to use a minimal Ubuntu server setup as a basis for the tutorial, that can be a virtual or a root server image with an Ubuntu 16.04 minimal install from a web hosting company or you use our minimal server tutorial to install a server from scratch.

Install Git on Ubuntu 16.04

Step 1. First, ensure your system and apt package lists are fully up-to-date by running the following:

apt-get update -y
apt-get upgrade -y

Step 2. Installing  Git.

Now let’s install git:

apt-get install git

You can check the version of git that was installed by using the following command:

git --version

Step 3. Configuration of Git on CentOS 7.

The first thing that you might want to do after the installation is to configure your own name and email address in Git so the changes you commit contain the correct information. You can do that by using the following commands:

git config --global "rezkia"
git config --global ""

Next we’ll verify the configuration changes by viewing the .gitconfig:

git config --list

For more information and command line options you can use the –help flag:

git --help

Congratulation’s! You have successfully install and configured Git on your Ubuntu 16.04 server. Thanks for using this tutorial installing Git on Ubuntu 16.04 LTS (Xenial Xerus) system.

The Tags:

Leave a Comment

Comments are closed.