所有Yeoman发电机装置都会造成大量错误

时间:2013-11-13 15:20:41

标签: node.js generator npm yeoman

在通过npm安装生成器后,我遇到了运行生成器的问题。在安装yoeman,grunt和bower以及任何生成器之后,任何在新文件空间中运行生成器的尝试(例如,你的webapp,yo骨干等)都会导致多个我不理解的错误消息。

Error: CERT_UNTRUSTED
  at SecurePair.<anonymous> (tls.js:1356:32)
  at SecurePair.EventEmitter.emit (events.js:92:17)
  at SecurePair.maybeInitFinished (tls.js:968:10)
  at CleartextStream.read [as _read] (tls.js:462:15)
  at CleartextStream.Readable.read (_stream_readable.js:320:10)
  at EncryptedStream.write [as _write] (tls.js:366:25)
  at doWrite (_stream_writable.js:221:10)
  at writeOrBuffer (_stream_writable.js:221:5)
  at EncryptedSteam.Writable.write (_stream_writable.js:180:11)
  at write (_stream_readable.js:583:24)

npm ERR! ENOENT, lstat 'c:\Users\ \yo-test\node_modules\grunt-contrib-imagemin\node_modules\jpegtran-bin\node_modules\bin-wrapper\node_modules\mout\array\inser.js'
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Program Files\\node.js\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! cwd C:\Users\ \yo-test
npm ERR! node -v v0.10.21
npm ERR! npm -v 1.3.11
npm ERR! path c:\Users\ \yo-test\node_modules\grunt-contrib-imagemin\node_modules\jpegtran-bin\node_modules\bin-wrapper\node_modules\mout\array\insert.js
npm ERR! fstream_path c:\Users\ \yo-test\node_modules\grunt-contrib-imagemin\node_modules\jpegtran-bin\node_modules\bin-wrapper\node_modules\mout\array\insert.js
npm ERR! fstream_type File
npm ERR! fsteam_class FIleWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! weird error 8
npm ERR!
npm ERR! not ok code 0>

任何帮助将不胜感激,并提前感谢!

  • JD

2 个答案:

答案 0 :(得分:1)

'〜/ .bowerrc'中的以下配置似乎可以解决它:

{
    "strict-ssl": false
}

答案 1 :(得分:0)

请参阅凉亭的Github中的this relevant issue

~/.bowerrc中,将端点设置为http

{
  "endpoint": "http://bower.herokuapp.com"
}