Skip to content

Instantly share code, notes, and snippets.

@cuiwm
Created June 6, 2017 08:27
Show Gist options
  • Save cuiwm/5c8421d4ceccfa9503b17a857929cbdd to your computer and use it in GitHub Desktop.
Save cuiwm/5c8421d4ceccfa9503b17a857929cbdd to your computer and use it in GitHub Desktop.
使用于github或者是局域网中git服务器
~$ cd ~/.ssh/
~$ touch config
在.ssh目录下创建一个config文件,输入如下内容:
Host github.com
User xxx@163.com (你注册github时的邮箱,这里使用注册的用户名也行)
Hostname ssh.github.com
PreferredAuthentications publickey
IdentityFile ~/.ssh/id_rsa
Port 443
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment