- SSH Keys with multiple Github accounts https://medium.com/@trionkidnapper/ssh-keys-with-multiple-github-accounts-c67db56f191e
There are 3 levels of git config; project, global and system.
-
project: Project configs are only available for the current project and stored in .git/config in the project's directory.
$ git config user.name "John Doe"
-
global: Global configs are available for all projects for the current user and stored in ~/.gitconfig.
$ git config --global user.name "John Doe"
-
system: System configs are available for all the users/projects and stored in /etc/gitconfig.
$ git config --system user.name "John Doe"
-
GLOBAL CONFIG
-
Set $HOME/.gitconfig by using the following:
git config --global user.name "your name" git config --global user.email [email protected]
this creates a .gitconfig file in the $HOME
-
Set project level git config:
git config user.name "your name" git config user.email [email protected]
-
Carrying your GIT settings around https://cweiske.de/tagebuch/carry-git-settings.htm
-
Can I specify multiple users for myself in .gitconfig?
https://stackoverflow.com/questions/4220416/can-i-specify-multiple-users-for-myself-in-gitconfig
-
Multiple github accounts on the same computer? https://stackoverflow.com/questions/3860112/multiple-github-accounts-on-the-same-computer
-
Quick Tip: How to Work with GitHub and Multiple Accounts
(Good article with Video)
-
List keys added to ssh-agent with ssh-add
ssh-add -l
with a resource name
ssh-add -L
to print with full key
-
Change the author and committer name and e-mail of multiple commits in Git
amend each commit:
git commit --amend --author "New Author Name <[email protected]>"
if shell environment variable
GIT_COMMITTER_EMAIL
and/orGIT_AUTHOR_EMAIL
is present then the git local config would not be used -
Creating a Happy Git Environment on OS X https://gist.github.com/trey/2722934