Git Setup: Your Name & Email

Free Git Tutorial

Discover how to set up Git for collaborative projects by inputting your name and email, allowing other developers to identify your contributions.

This exercise is excerpted from Noble Desktop’s Git & GitHub training materials and is compatible with updates through 2022. To continue learning web development with hands-on training, check out our coding bootcamps in NYC and live online.

Setting Up Git

Git helps you to work with other developers. Because you want to know who worked on a file and how to contact them, you must tell Git your name and email.

Tell Git Your Name & Email

  1. To access the command line, do the following instructions for your platform:

    • Mac: Go to Applications > Utilities and open Terminal.app.
    • Windows: Launch the Git Bash app, which may be an icon on your Desktop, or in the Windows Start menu (probably in a Git folder).
  2. Enter the following command, replacing Your Name with your actual first and last name (but keep the quotes around it):

    git config --global user.name "Your Name"

  3. Enter the following command, replacing you@example.com with your actual email (but keep the quotes around it):

    git config --global user.email "you@example.com"

Full-Stack Web Development Certificate: Live & Hands-on, In NYC or Online, 0% Financing, 1-on-1 Mentoring, Free Retake, Job Prep. Named a Top Bootcamp by Forbes, Fortune, & Time Out. Noble Desktop. Learn More.

Keep in mind that changing the name and email will only affect future work.

Checking Your Git Setup (Name & Email)

To check the name or email currently set in git, you can run the same commands, but without the value in quotes. So you’d use these commands:

git config --global user.name
git config --global user.email
photo of Dan Rodney

Dan Rodney

Dan Rodney has been a designer and web developer for over 20 years. He creates coursework for Noble Desktop and teaches classes. In his spare time Dan also writes scripts for InDesign (Make Book JacketProper Fraction Pro, and more). Dan teaches just about anything web, video, or print related: HTML, CSS, JavaScript, Figma, Adobe XD, After Effects, Premiere Pro, Photoshop, Illustrator, InDesign, and more.

More articles by Dan Rodney

How to Learn Git

Master Git with hands-on training. Git is a free, open-source version control system that allows developers to track the changes they make to code.

Yelp Facebook LinkedIn YouTube Twitter Instagram