Skip to content

Instantly share code, notes, and snippets.

@akhansari
Last active Jun 7, 2022
Embed
What would you like to do?
Multiple Git Configs
[core]
excludesFile = ~/.gitignore
[user]
name = My Name
[includeIf "gitdir:~/git/"]
path = ~/.gitconfig-work
[includeIf "gitdir:~/github/"]
path = ~/.gitconfig-home
Host mydomain mydomain.com
HostName mydomain.com
IdentityFile ~/.ssh/id_rsa
Host github github.com
HostName github.com
IdentityFile ~/.ssh/id_rsa_home
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment