git拉去代碼提示以下錯誤:
”Warning: Permanently added 'gitlab.xxx.com,10.16.36.43' (ECDSA) to the list of known hosts.
git@gitlab.xxx.com: Permission denied (publickey,gssapi-keyex,gssapi-with-mic).
fatal: Could not read from remote repository.“
大概意思就是說我要clone的項目的這個gitlab的主機不可知,需要讓我配置一下。
【問題解決】 參考文章:https://blog.csdn.net/weixin_39340288/article/details/81541817
1.cmd 命令界面錄入ssh-keygen -t rsa -C "xxx@xxx.com" //重新生成rsa key
2.一直enter鍵,即可生成新的key,如上圖所示。
3.去指定目錄找到 id_rsa 文件,如下圖所示。
4.將文件中的id_rsa內容全部復制到粘貼到github,個人setting--SSH and GPG keys 添加 個新的key