Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

setup git config for multiple accounts

# to set user on a per repo basis run the following commands in the project/repo root directory
git config user.name "My Special Repo Account User Name"
git config user.email myspecialrepoaccount@email.com

# to set a global/default git user run the following commands anywhere
git config --global user.name "My Default Account User Name"
git config --global user.email mydefault@email.com
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #setup #git #config #multiple #accounts
ADD COMMENT
Topic
Name
8+6 =