会哭的雨 2020-06-11
配置 sshkey
cd / 根目录
*生成key:ssh-keygen -t rsa -C “邮箱地址”
*cd ~/.ssh(用户目录下的.ssh文件夹)
pwd
cat id_rsa_.pub
*复制id_rsa.pub的公钥内容到github官网中 settings >SSH and GPG keys >New SSH Key
配置多个 sshkey
*cd ~/.ssh(用户目录下的.ssh文件夹)
*vim config
* 添加Host/HostName/User/IdentityFile 四项
host:github.com
HostName:github.com
User:git用户名
IdentityFile:id_rsa