Configure Git for the first time

Git for beginners

When you start using Git in a new computer you need to setup some basic steps to configure Git for the first time, and to be ready to work in a git console.

Install Git

The install process could be different for each OS. However, here is a list of the most common operating system installation steps:

  • MacOS:
  • Linux
    • Debian/Ubuntu (sudo apt-get install git)
    • CentOS  (sudo yum install git)
    • Fedora (sudo yum install git-core)
  • Windows


After installing GIT you will get a set of tools depending on your operating system:

  • The GIT command-line interface: you can enter from your console application, and then run git commands from there.
  • Git Bash: for Windows users, it’s a Linux-like terminal with access to git commands in a more standard way (for example, to run npm commands)
  • A Git GUI: for Windows users, it’s a visual interface to perform GIT operations.

Configure Git for the first time

Before running some git commands for the first time, for example, to commit and push changes to a repository, it’s important to configure a couple of global variables used for those transactions. Otherwise, you could get some warning messages about this.

Global variables

  • Set the git global user name (git config --global "myname")
  • Set the git global email (git config --global "")


Related articles

Useful GIT commands for everyday use

Git for Beginners

Leave a Reply