One even-better approach IMHO Just keep a .gitconfig in your HOME with aliases for your identities. Then just after initializing/cloning the repo do git config-company or git config-personal er453r@r7:~$ cat ~/.gitconfig [user] useConfigOnly = true [alias] config-personal = !echo CONFIG-PERSONAL && \ git config --local user.email 'personal@email.com' && \ git config --local user.name 'personal' && \ git config --loca…
How would you do the initial clone without the correct ssh config to begin with? I think the benefit of the article's method is that any clone from their org will just work .
I just like this workflow better since it is totally directory/remote agnostic (compared to the article).
Just use whatever suits you best :)