I like to have separate "identities" for my private and work stuff when using Git: Commits at work should be authored with my work email and commit...
For further actions, you may consider blocking this person and/or reporting abuse
.gitconfig
That's even better 🥺 Thanks
Thanks this is really helpful. I used to manually edit the
.git/config
directory by appending the[user]
information for every work related repo. This is a much better way :)Nice! Should it be changed?
From:
[includeIf "gitdir:~/Work/"]
path = .gitconfig-work
To:
[includeIf "gitdir:~/Work/"]
path = ~/.gitconfig-work
It's not necessary to specify the full path. The path is relative to the location of the
.gitconfig
file itself, therefore it works in this case both ways.But to make it easier to understand, the fullpath is probably a better example.
Thank you so much for this!
Thanks, that's awesome!
This is amazing. Thank you!
Very useful! I used to set git config every time I cloned a repo, so this must save a lot of time and headaches! Thank you
Nice, this is super useful. I didn't even know I needed this. Thank you!