ssh-keygen -t rsa -C "your_email@example.com"
This method directly overwrites the public key under ~/.ssh/id_rsa.pub.
I want to add multiple public keys, how do I do it/
巴扎黑2017-05-02 09:42:46
ssh-keygen -f ~/.ssh/osckeyfile
Then add the ~/.ssh/config file, configure the git domain name, and your ssh private key path above
Host git.oschina.net # 我没用过,你换osc的域名
IdentityFile ~/.ssh/osckeyfile
PS: Multiple websites can use the same key and do not have to be separated