In this article, we will have explained the necessary steps to install and configure Git on Debian 10. Before continuing with this tutorial, make sure you are logged in as a user with
sudo privileges. All the commands in this tutorial should be run as a non-root user.
Git is the most popular version control system nowadays. It helps to share and collaborate on software development projects. Git is mainly used for source code management.
Install Git on Debian
Step 1. The first command will update the package lists to ensure you get the latest version and dependencies.
sudo apt update sudo apt upgrade
Step 2. Install Docker on Debian system.
The installation is pretty straightforward, just run the following commands as a user with
sudo apt install git
Confirm the installation and check the version executing the following command:
git version 2.20.1
Step 3. Configuring Git.
First set the global user name for Git:
git config --global user.name "User Name"
Secondly set global email for Git:
git config --global user.email "YourUserName@domain.com"
You can verify the changes with the following command:
### git config --list user.name=User Name email@example.com
The configuration settings are stored in the ~/.gitconfig file:
[user] name = Your Name email = firstname.lastname@example.org
That’s all you need to do to install Git on Debian 10 Buster. I hope you find this quick tip helpful. For further reading on Git, please refer to their official knowledge base. If you have questions or suggestions, feel free to leave a comment below.