Method of operation
- Open the terminal or
git Bash
Generate a public key and a private key
1
2$ ssh-keygen -t rsa -f ~/.ssh/id_rsa_1 -C "[email protected]"
$ ssh-keygen -t rsa -f ~/.ssh/id_rsa_2 -C "[email protected]"Create a
config
file1
touch config
In
config
add the following file
1 |
# one([email protected]) |
- SSH key deployment
were landed two github account, enter the Personal settings -> SSH and GPG keys , the corresponding.pub
contents added to it. Testing SSH link
1
2ssh -T [email protected]
ssh -T [email protected]Set into the warehouse user
1
2
3
4
5
6
7
8
9
10# Cancellation global user name / mailbox configuration
git config -global -unset user.name
git config -global -unset user.email
# Set individually for each repo username / mailbox
git config user.email "[email protected]"
git config user.name "One"
git config user.email “[email protected]”
git config user.name “two”
Remark
If you are using hexo build blog, Part 7 should .deploy_git
be a folder or directly modify .deploy_git.git
the config
file, add the following:
1 |
[user] |
Reference material
- A computer bind two github account tutorial
- git repository different accounts of different solutions
Original: Large column using multiple github account management warehouse