git 生成秘钥
生成git秘钥
1.设置账号和邮箱
git config --global user.name “自已的名字” 例:git config --global user.name “lijianye”
git config --global user.email “自己的邮箱” 例:git config --global user.email “lijianye@qq.com”
2.查看秘钥是否存在
cd ~/.ssh
3.生成秘钥
ssh-keygen -t rsa -C “zhangsan@qq.com”
4.然后把秘钥拷贝到git上:(下方文件中的内容)
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/b69061f0fc73488173ef068b7eba3bb1.png)