Languages
[Edit]
EN

Git - how to show username and email?

10 points
Created by:
Root-ssh
178430

In this article, we would like to answer for the question: how to show username and email fot current configuration in Git.

Quick solution:

Hint: check section 2 and 3 to see difference between global and single repositiory configuration.

 

1. Overview

Edit

Depending on where and what command we run, we can get:

  • global configuration,
  • local configuration (single repository configuration).

The same Git configuration works under Windows, Linux and macOS.

 

2. Global username and email configuration

Edit

Simple steps:

  1. Open command line, e.g. Git Bash,
  2. Show username and email by typing:

Note: it returns always global configuration.

 

3. Local username and email configuration (current single repository)

Edit

Simple steps:

  1. Open command line, e.g. Git Bash,
  2. Change directory into specific repository directory,
    e.g. cd /path/to/reporitory,
  3. Show username and email by typing:

Note: it returns always global configuration outside repository directory and local configuration inside repository directory.

 

See also

Edit
  1. Git - how to set username and email?

References

Edit
  1. Git config - Docs
  2. Getting Started - First-Time Git Setup
  3. Github - Setting your commit email address
1
Donate to Dirask
Our content is created by volunteers - like Wikipedia. If you think, the things we do are good, donate us. Thanks!
Join to our subscribers to be up to date with content, news and offers.

Git

Native Advertising
🚀
Get your tech brand or product in front of software developers.
For more information Contact us
Dirask - we help you to
solve coding problems.
Ask question.

❤️💻 🙂

Join