Git clone git@git.coding.net:账户 /项目.git
上面以SSH方式访问用项目出现权限问题
Permissiondenied (publickey).
fatal:Could not read from remote repository.
Pleasemake sure you have the correct access rights
andthe repository exists.
解决方法:
在git.bash.窗口输入
ssh-keygen–t rsa –c”你的邮箱地址”
ssh-keygen -t rsa -C "邮箱地址"
然后一直回车就行
操作成功后会在
C:\Users\Administrator目录下生成一个.ssh目录,内容如下
Id-rsa是你的私钥,用笔记本方式打开id_rsa.pub把里面的公钥复制到coding.net的账户下面的SSH公钥下
然后重新输入
Git clone git@git.coding.net:账户 /项目.git就OK了