Skip to content


Configure Git user information

Configuring Git user information is essential to associate commits with a user. This information is used to identify the author of a commit and is displayed in the commit history.

You can either set this information globally (for all repositories) or locally (for the current repository). In both cases, you need to use git config to specify the user information.

More specifically, you can use git config <email> to set the user's email and git config <name> to set the user's name. You can also use the --global flag to configure global user information.

# Syntax:
#  git config [--global] <email>
#  git config [--global] <name>

# Configure user for current repository
git config ""
git config "Duck Quackers"

# Configure global Git user
git config --global ""
git config --global "Duck Quackers"

More like this

Start typing a keyphrase to see matching snippets.