Host github.com
HostName ssh.github.com
Port 443 User git
IdentityFile ~/.ssh/github
有多个 github 用户时
ssh config:
1
2
3
4
5
6
7
8
9
10
11
Host github.com
HostName ssh.github.com
Port 443
User git
IdentityFile ~/.ssh/github
Host github.com-<the other user name>
HostName ssh.github.com
Port 443
User git
IdentityFile ~/.ssh/github-joshua
clone:
1
2
git clone git@github.com:xxx/xxx.git
git clone git@github.com-<the other user name>:xxx/xxx.git