Wednesday, June 1, 2016

GIT: Configure Global User

In case you need to set up both the global user name and email in git, you need to provide the following commands:

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

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

Please be careful when executing the above commands as these will override the current settings.

In case you want to commit/push as a different user without affecting the global settings, you can try:

git commit --amend --author='Your Name <you@example.com>'

For more information on git Commands: https://git-scm.com/docs

No comments:

Post a Comment