(已解决)npm ERR! command failed npm ERR! command git ls-remote ssh://git@github.com/nhn/raphael.git

Posted 知识浅谈

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了(已解决)npm ERR! command failed npm ERR! command git ls-remote ssh://git@github.com/nhn/raphael.git相关的知识,希望对你有一定的参考价值。


这个错必须要记录一下了,看了网上很多的解决方法,最后终于找到原因了,

npm ERR! code 128
npm ERR! command failed
npm ERR! command git ls-remote ssh://git@github.com/nhn/raphael.git
npm ERR! git@github.com: Permission denied (publickey).
npm ERR! fatal: Could not read from remote repository.
npm ERR! Please make sure you have the correct access rights
npm ERR!

之所以是这样,是因为本地生成的SSH keys添加到github里面,,这个生成的SSH keys 是带有密码的

解决方法
桌面右键,git bash here
输入以下
ssh-keygen -t rsa -C “你的邮箱名称”
overwrite 输入y
输入密码的时候直接回车
重复密码输入还是直接回车,然后把github上以前的sshkeys删除,c盘->用户->你的用户名->.ssh->id_rsa.pub里边的字符添加到 github右上角头像->settings->ssh & GPG ->Add sshKeys
第二个大框里输入确认即可

基本上绝大部分同学上边弄完之后就可以了

以上是关于(已解决)npm ERR! command failed npm ERR! command git ls-remote ssh://git@github.com/nhn/raphael.git的主要内容,如果未能解决你的问题,请参考以下文章

React项目创建报错解决方案npm ERR! code 1 npm ERR! path E:Node1untitled5 ode_modulesfibers npm ERR! command(代码片

npm 报错: npm ERR! Please try running this command again as root/Administrator.

(Bug终结者)npm ERR! Command failed: git clone --mirror -q git://github.com/adobe-webplatform/eve.git

错误“由于 npm ERR 中的错​​误,您的缓存文件夹包含 root 拥有的文件!以前版本的 npm 已得到解决”

已解决执行./Scripts/bootstrap.sh报错npm ERR! code ERESOLVE

已解决执行./Scripts/bootstrap.sh报错npm ERR! code ERESOLVE