linux中如何通过ssh连接github

生成新的ssh,放置在/data/.ssh/目录下

1
2
ssh-keygen -t rsa -C "821192673@qq.com"
#为邮箱地址

将生成的私钥加入ssh-agent中

1
2
3
#判断ssh-agent是否启动
eval "$(ssh-agent -s)"
ssh-add /data/.ssh/id_rsa
阅读更多