准备工作
- 下载并安装git
- 打开git,定义邮箱和name
git config --global user.email "@qq.com"
git config --global user.name "xy"
- 找到代码目录,鼠标右键 — git Bash here,生成密钥(邮箱补全)
ssh-keygen -t rsa -C "@qq.com"
- 查看生产的密钥,复制
cat ~/.ssh/id_rsa.pub
- 打开gitee — 设置 — SSH公钥,粘贴进去
git config --global user.email "@qq.com"
git config --global user.name "xy"
ssh-keygen -t rsa -C "@qq.com"
cat ~/.ssh/id_rsa.pub