Git: Set Name and Email

Listing your current settings

Type the following to verify the settings of your current project.


git config --list

You can add the flag --show-origin to discover where the settings comes from (i.e. is it a global setting or this project's setting)

Set your identity

The following two commands will set your user's name and email.


git config --global user.name "Jane Smith"
git config --global user.email "jane.smith@organization.org"

The previous will set your information globally on your system. Which means that it will be the same for every project you work on.

Removing the --global flag with set your name and email to the current project only.

Next Step

Links

Advertisement