You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When removing an identity we'll want it to search for all includeIf settings where idm key is equal to the identity being removed. We'll also want to delete the file.
Using the prefix .gitconfig_idm_[git idm identity] for the file seems like the best way to avoid clashing with potential user configuration files.
The text was updated successfully, but these errors were encountered:
This feature has been implemented in 0.7 release. I changed around the option names based on limitations in current program design. I tried making sense of the option naming as much as possible. I don't think the result is that bad and is helpful for configuring an advanced git feature easily.
Let's say you have a work identity and a personal identity.
git idm track work --directory ~/git/work
git idm track work --directory ~/git/work2
git idm track personal --directory ~/git/github
List directories associated with a given identity. The directories will auto-switch to the identity for git commit authorship and private key for pushing over SSH.
git idm list work --tracked
Removing identities and running git idm uninstall will have expected cleanup behavior.
https://dev.to/maxlmator/maintaining-different-git-identities
It would be nice for identities to auto-select based on a local directory (optionally given).
And the contents of
/home/sam/.gitconfig_idm_github
would be...Assuming that the
git idm
identity is...This will require a minimum version of git 2.13.0 for this.
Brainstorming feature
I think it makes sense to add this as a sub-command
git idm directory
which associates the identity name with the directory.We could tie the identity with an
idm
subkey in.gitconfig
like:When removing an identity we'll want it to search for all
includeIf
settings whereidm
key is equal to the identity being removed. We'll also want to delete the file.Using the prefix
.gitconfig_idm_[git idm identity]
for the file seems like the best way to avoid clashing with potential user configuration files.The text was updated successfully, but these errors were encountered: