Created
February 13, 2019 07:53
-
-
Save condran/8cd212cc3d262fed3e3ba3bcbd0e36aa to your computer and use it in GitHub Desktop.
How to have conditional config for personal and work git user accounts
https://dev.to/maxlmator/maintaining-different-git-identities
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ~/.gitconfig | |
[user] | |
name = Firstname Lastname | |
email = <private email address> | |
[includeIf "gitdir:~/Work/"] | |
path = .gitconfig-work |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ~/.gitconfig-work | |
[user] | |
name = Lastname, Firstname | |
email = <work email address> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment