学习廖雪峰老师的git教程,到了git push这一步遇到了很多麻烦。
多次尝试都会在这两个结果里徘徊 :Connection closed by remote host 以及
fatal: Could not read from remote repository。
之后在hosts文件中添加了192.30.253.112 ssh.github.com
并在.ssh文件夹中添加了config文件
Host github.com
User youremail@163.com
Hostname ssh.github.com
PreferredAuthentications publickey
IdentityFile ~/.ssh/id_rsa
Port 22
终于可以提交
自我建议:
1.学习ssh相关内容
2.学习TCP/IP相关内容
3.不要放弃尝试