【发布时间】:2017-03-18 20:52:56
【问题描述】:
我正在尝试学习 node、npm 和 gulp,但都遇到了这个错误。
$ npm install --save-dev gulp
npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "--save-dev" "gulp"
npm ERR! node v6.10.0
npm ERR! npm v3.10.10
npm ERR! code SELF_SIGNED_CERT_IN_CHAIN
npm ERR! self signed certificate in certificate chain
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR! <https://github.com/npm/npm/issues>
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\davidb\desktop\testproject\npm-debug.log
有谁知道如何解决这个问题?我使用 gitbash 而不是节点,因为在我的节点中我什至不能做 node-v 我必须使用 process.version 来获取版本。非常感谢您的帮助!我一直在使用http://blog.npmjs.org/post/78165272245/more-help-with-selfsignedcertinchain-and-npm 尝试解决此问题,但没有任何效果。
也试过了:
npm config set ca ""
and
npm install npm -g --ca=""
两者都不起作用,我仍然收到错误 npm ERR!代码 SELF_SIGNED_CERT_IN_CHAIN
【问题讨论】:
标签: node.js npm gulp npm-install