Linux上如何配置GitHub免密
June 12, 2020, 6:15 p.m.
read: 1325
Step 1
运行一下命令
cat ~/.ssh/id_rsa.pub
如果输出公钥信息,则跳转到Step 2
不然执行以下命令
ssh-keygen -t rsa
然后按2次回车
Step 2
浏览器输入 https://github.com/settings/ssh/new
cat ~/.ssh/id_rsa.pub
将以上的命令输出的公钥信息粘到网页的Key栏目里面
保存即可
Step 3
运行一下命令
ssh -T git@github.com
如果输出以下内容则表示配置成功。Hi ???! You've successfully authenticated, but GitHub does not provide shell access.