Multi GitHub Accounts Use. Implement a command.

TheCukitoDev
TheCukitoDev
Community Member

Hello, I had a problem and I am going to post it here to help anyone that has the same problem. I have 2 accounts of GitHub and I have the problem to use both of the accounts when I need and use 1password to have the private keys. I use this config for this git agent.toml
[[ssh-keys]] vault = "Personal" and use a ~/.ssh/config file : ```

Acc 2

Host
HostName github.com
User git
IdentityFile ~/.ssh/
IdentitiesOnly yes

Acc 2

Host
HostName github.com
User git
IdentityFile ~/.ssh/
IdentitiesOnly yes


I have created a folber with a sys path and then i put the file in the sys path folder and only had to put the name of the file in the terminal and it is configured for your multiaccount git setup.


1Password Version: 1Password for Windows 8.10.36 (81036046)
Extension Version: 2.25.1
OS Version: Windows 11 Pro 23H2
Browser: Brave v1.67.134