2012-02-09 121 views
2

運行npm install jasmine-jquery給出如下圖所示的錯誤輸出。 我正在運行Windows 7.任何想法?NPM安裝茉莉花jQuery的失敗

npm install jasmine-jquery 
npm http GET https://registry.npmjs.org/jasmine-jquery 
npm http 304 https://registry.npmjs.org/jasmine-jquery 
npm http GET https://registry.npmjs.org/jsdom 
npm http 304 https://registry.npmjs.org/jsdom 
npm http GET https://registry.npmjs.org/request 
npm http GET https://registry.npmjs.org/cssom 
npm http GET https://registry.npmjs.org/contextify 
npm http GET https://registry.npmjs.org/htmlparser 
npm http 304 https://registry.npmjs.org/cssom 
npm http 304 https://registry.npmjs.org/htmlparser 
npm http 304 https://registry.npmjs.org/request 
npm http 304 https://registry.npmjs.org/contextify 

> [email protected] preinstall C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\contextify 
> node-waf clean || (exit 0); node-waf configure build 

Oväntat node-waf. 
npm ERR! error installing [email protected] 
npm ERR! error installing [email protected] 
npm ERR! Error: ENOENT, no such file or directory 'C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\___htmlparser.npm\package\runtests.min.js' 
npm ERR! Report this *entire* log at: 
npm ERR!  <http://github.com/isaacs/npm/issues> 
npm ERR! or email it to: 
npm ERR!  <[email protected]> 
npm ERR! 
npm ERR! System Windows_NT 6.1.7600 
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "jasmine-jquery" 
npm ERR! cwd C:\node\messagemetrics 
npm ERR! node -v v0.6.6 
npm ERR! npm -v 1.1.0-beta-4 
npm ERR! path C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\___htmlparser.npm\package\runtests.min.js 
npm ERR! fstream_path C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\___htmlparser.npm\package\runtests.min.js 
npm ERR! fstream_type File 
npm ERR! fstream_class FileWriter 
npm ERR! code ENOENT 
npm ERR! message ENOENT, no such file or directory 'C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\___htmlparser.npm\package\runtests.min.js' 
npm ERR! fstream_stack Object.oncomplete (C:\Program Files\nodejs\node_modules\npm\node_modules\fstream\lib\writer.js:204:26) 
npm ERR! error rolling back [email protected] Error: UNKNOWN, unknown error 'C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\___request.npm\package\tests' 
npm ERR! error installing [email protected] 
npm ERR! error rolling back [email protected] Error: UNKNOWN, unknown error 'C:\node\node_modules\jasmine-jquery\node_modules\jsdom\node_modules\___request.npm\package' 
npm ERR! [email protected] preinstall: `node-waf clean || (exit 0); node-waf configure build` 
npm ERR! `cmd "/c" "node-waf clean || (exit 0); node-waf configure build"` failed with 1 
npm ERR! 
npm ERR! Failed at the [email protected] preinstall script. 
npm ERR! This is most likely a problem with the contextify package, 
npm ERR! not with npm itself. 
npm ERR! Tell the author that this fails on your system: 
npm ERR!  node-waf clean || (exit 0); node-waf configure build 
npm ERR! You can get their info via: 
npm ERR!  npm owner ls contextify 
npm ERR! There is likely additional logging output above. 
npm ERR! 
npm ERR! System Windows_NT 6.1.7600 
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "jasmine-jquery" 
npm ERR! cwd C:\node\messagemetrics 
npm ERR! node -v v0.6.6 
npm ERR! npm -v 1.1.0-beta-4 
npm ERR! code ELIFECYCLE 
npm ERR! message co[email protected] preinstall: `node-waf clean || (exit 0); node-waf configure build` 
npm ERR! message `cmd "/c" "node-waf clean || (exit 0); node-waf configure build"` failed with 1 
npm ERR! 
npm ERR! Additional logging details can be found in: 
npm ERR!  C:\node\messagemetrics\npm-debug.log 
npm not ok 
+0

https://github.com/isaacs/npm/issues/2061 「這是一個jsdom錯誤。它應該列出contextify作爲optionalDependency,或不使用它。節點WAF將永遠工作在Windows 。「 – 2012-02-09 12:49:20

回答

-1

您是否嘗試過使用sudo? 這工作對我來說:sudo npm安裝jasmine-jquery,讓我知道如果這對你有用。

+0

OP說他正在使用Windows 7 – gztomas 2014-05-21 16:39:11