本文共 1070 字,大约阅读时间需要 3 分钟。
cd ~/.ssh
$ ssh-keygen -t rsa -C "xxxxxxx@xxx.com"
按3个回车,密码为空,得到:
Your identification has been saved in /home/tekkub/.ssh/id_rsa.Your public key has been saved in /home/tekkub/.ssh/id_rsa.pub.The key fingerprint is:………………
最后得到了两个文件:id_rsa
和id_rsa.pub
ssh-add 文件名
id_rsa.pub
里面的公钥: 打开https://github.com/
,登陆,然后添加ssh。git config --global user.name "xxxxxx"git config --global user.email "xxxxxx@xxx.com"git config --global push.default simple
git config user.name "xxxxx"git config user.email "xxxxx@xxx.com"
$ mkdir test$ cd test
$ git init
转载地址:http://wokvb.baihongyu.com/