NPM安装依赖时遇到问题:code ENOENT errno 34的一种解决解决方法

package.json中有一条这样的依赖配置:

"grunt-include-replace": "https://github.com/coderhaoxin/grunt-include-replace"

 

node -v v0.10.17

npm -v 1.3.8

 

npm ERR! not a package /var/folders/59/5j0mz14d2yd5hg0x0x92jwhw0000gn/T/npm-1050-_7eFLvWt/1378885917128-0.5969314440153539/tmp.tgz
npm ERR! Error: ENOENT, open '/var/folders/59/5j0mz14d2yd5hg0x0x92jwhw0000gn/T/npm-1050-_7eFLvWt/1378885917128-0.5969314440153539/package/package.json'
npm ERR! If you need help, you may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>

npm ERR! System Darwin 12.4.0
npm ERR! command "node" "/usr/local/bin/npm" "install"
npm ERR! cwd /Users/expro/github/fancy
npm ERR! node -v v0.10.17
npm ERR! npm -v 1.3.8
npm ERR! path /var/folders/59/5j0mz14d2yd5hg0x0x92jwhw0000gn/T/npm-1050-_7eFLvWt/1378885917128-0.5969314440153539/package/package.json
npm ERR! code ENOENT
npm ERR! errno 34
npm http 200 https://registry.npmjs.org/jade
npm http GET https://registry.npmjs.org/jade/-/jade-0.35.0.tgz
npm http 200 https://registry.npmjs.org/express/-/express-3.3.8.tgz
npm http 200 https://registry.npmjs.org/request/-/request-2.25.0.tgz
npm http 200 https://registry.npmjs.org/validator/-/validator-1.4.0.tgz
npm http 200 https://registry.npmjs.org/jade/-/jade-0.35.0.tgz
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/expro/github/fancy/npm-debug.log
npm ERR! not ok code 0

我最后的解决办“https改成"git" ,解决了问题

你可能感兴趣的:(node.js)