git生成ssh key for mac

打开终端 cd ~/.ssh 看有没有文件

没有的时候

mac上的git环境配置

有有ssh key是这样的多了id_rsa(私钥)和 id_rsa.pub(公钥)

mac上的git环境配置

没有的话创建

ssh-keygen -t rsa -C "youremail"  (这个是你github上你的账户注册时候的eamil)

mac上的git环境配置

然后 你可以cd ~/.ssh 

cat id_rsa.pub 里面的公钥复制出来,添加到你的账户上

mac上的git环境配置

mac上的git环境配置

添加之后,你就可以创建一个文件夹,在这个文件夹内就可以git clone 你账户上的仓库了,

git clone git@github.com:wufangfang0614/fanggit.git

然后你就可以开发了,其他操作,可以看我的其他git教程。

 

相关文章:

  • 2021-05-06
  • 2022-12-23
  • 2021-04-14
  • 2021-04-28
  • 2021-06-19
  • 2021-07-10
  • 2021-09-01
  • 2021-12-22
猜你喜欢
  • 2021-07-04
  • 2021-08-26
  • 2022-02-10
  • 2022-12-23
  • 2022-12-23
  • 2021-12-19
  • 2021-04-11
相关资源
相似解决方案