首页 > 其他 > 详细

Githup仓库使用密匙连接

时间:2021-05-05 11:38:44      阅读:20      评论:0      收藏:0      [点我收藏+]

 

 

本地库生成密匙

 

$ git config --global user.name LIRUILONGS
$ git config --global user.email 1224965096@qq.com
$ ssh-keygen -t rsa -C "1224965096@qq.com"
 

 

lenovo@Liruilong MINGW64 /d/node/code/VueDemo (main)
$ git config --global user.name LIRUILONGS

lenovo@Liruilong MINGW64 /d/node/code/VueDemo (main)
$ git config --global user.email 1224965096@qq.com

lenovo@Liruilong MINGW64 /d/node/code/VueDemo (main)
$ ssh-keygen -t rsa -C "1224965096@qq.com"
Generating public/private rsa key pair.
Enter file in which to save the key (/c/Users/lenovo/.ssh/id_rsa):
Created directory /c/Users/lenovo/.ssh.
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /c/Users/lenovo/.ssh/id_rsa.
Your public key has been saved in /c/Users/lenovo/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256:QdyY4AUR/wU8De5ZF7/6GagKvd6ejzRYlNCkQtJvR+8 1224965096@qq.com
The keys randomart image is:
+---[RSA 2048]----+
|     .*Bo*=+  .  |
|     .o=+.*+o  o |
|      ..+.o++ . .|
|        .*.= o  .|
|        S =..  . |
|        . o  Eo  |
|       . o o o . |
|        . + = . o|
|        .+o*.. o |
+----[SHA256]-----+

lenovo@Liruilong MINGW64 /d/node/code/VueDemo (main)

找到密匙复制到Githup上

 

$ cd ~/.ssh/
$ cat id_rsa.pub

 

 技术分享图片

 

 


$ cd ~/.ssh/
lenovo@Liruilong MINGW64 ~/.ssh
$ cat id_rsa.pub
ssh-rsa AAAAB3NzaC1yc2EA3434ABAAABAQCkrUaQU/Li1cY3z0TTWrO34339fhYRlCNvPxkqEXcNLr343
lenovo@Liruilong MINGW64 ~/.ssh
$ pwd
/c/Users/lenovo/.ssh
lenovo@Liruilong MINGW64 ~/.ssh
 

 

技术分享图片

 

 

技术分享图片

 

Githup仓库使用密匙连接

原文:https://www.cnblogs.com/liruilong/p/14731072.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!