npm安装停止工作

时间:2015-10-09 11:45:49

标签: node.js powershell npm

我检查过很多stackoverflow的答案,但还没有找到任何可以解决我当前问题的问题,运行npm install之后安装只是停止一段时间后,这是命令的结果:npm install -verbose 我在Windows 10上运行,Powershell管理模式。

   ^CPS C:\Users\hjort\Documents\git\nuhet> npm install -verbose
   npm info it worked if it ends with ok
   npm verb cli [ 'C:\\Program Files\\nodejs\\node.exe',
   npm verb cli   'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-   cli.js',
   npm verb cli   'install',
   npm verb cli   '-verbose' ]
   npm info using npm@2.14.4
   npm info using node@v4.1.2
   npm verb readDependencies loading dependencies from C:\Users\hjort\Documents\git\nuhet\package.json
   npm verb install where, deps [ 'C:\\Users\\hjort\\Documents\\git\\nuhet',
   npm verb install   [ 'laravel-elixir',
   npm verb install     'bootstrap-sass',
   npm verb install     'gulp',
   npm verb install     'laravel-elixir-css-url-adjuster' ] ]
   npm verb install where, peers [ 'C:\\Users\\hjort\\Documents\\git\\nuhet', [] ]
   npm verb installManyTop reading for lifecycle C:\Users\hjort\Documents\git\nuhet\package.json
   npm info preinstall @
   npm verb readDependencies loading dependencies from C:\Users\hjort\Documents\git\nuhet\package.json
   npm verb cache add spec gulp@^3.8.8
   npm verb addNamed ">=3.8.8 <4.0.0" is a valid semver range for gulp
   npm verb addNameRange registry:https://registry.npmjs.org/gulp not in flight; fetching
   npm verb cache add spec laravel-elixir-css-url-adjuster@^3.0.0
   npm verb addNamed ">=3.0.0 <4.0.0" is a valid semver range for laravel-elixir-css-url-adjuster
   npm verb addNameRange registry:https://registry.npmjs.org/laravel-elixir-css-url-adjuster not in flight; fetching
   npm verb cache add spec laravel-elixir@^3.0.0
   npm verb addNamed ">=3.0.0 <4.0.0" is a valid semver range for laravel-elixir
   npm verb addNameRange registry:https://registry.npmjs.org/laravel-elixir not in flight; fetching
   npm verb cache add spec bootstrap-sass@^3.0.0
   npm verb addNamed ">=3.0.0 <4.0.0" is a valid semver range for bootstrap-sass
   npm verb addNameRange registry:https://registry.npmjs.org/bootstrap-sass not in flight; fetching
   npm verb request uri https://registry.npmjs.org/laravel-elixir-css-url-adjuster
   npm verb request no auth needed
   npm info attempt registry request try #1 at 13:34:57
   npm verb request id 02f42720181b5dc2
   npm verb etag "YKMBAE0ADCRKINBWWZE2VLG"
   npm http request GET https://registry.npmjs.org/laravel-elixir-css-url-adjuster
   npm verb request uri https://registry.npmjs.org/gulp
   npm verb request no auth needed
   npm info attempt registry request try #1 at 13:34:57
   npm verb etag "9LDNWINP8N9T19SMZNI424E8Q"
   npm http request GET https://registry.npmjs.org/gulp
   npm verb request uri https://registry.npmjs.org/bootstrap-sass
   npm verb request no auth needed
   npm info attempt registry request try #1 at 13:34:57
   npm verb etag "222LDEHR46XIS27VQ27I94MMD"
   npm http request GET https://registry.npmjs.org/bootstrap-sass
   npm verb request uri https://registry.npmjs.org/laravel-elixir
   npm verb request no auth needed
   npm info attempt registry request try #1 at 13:34:57
   npm verb etag "CLCFW1HL59PBEG7YUCVBFSBCP"
   npm http request GET https://registry.npmjs.org/laravel-elixir
   npm http 304 https://registry.npmjs.org/gulp
   npm verb etag https://registry.npmjs.org/gulp from cache
   npm verb get saving gulp to C:\Users\hjort\AppData\Roaming\npm-cache\registry.npmjs.org\gulp\.cache.json
   npm verb addNamed "3.9.0" is a plain semver version for gulp
   npm http 304 https://registry.npmjs.org/laravel-elixir
   npm verb etag https://registry.npmjs.org/laravel-elixir from cache
   npm verb get saving laravel-elixir to C:\Users\hjort\AppData\Roaming\npm-cache\registry.npmjs.org\laravel-elixir\.cache.json
   npm verb addRemoteTarball https://registry.npmjs.org/gulp/-/gulp-3.9.0.tgz not in flight; adding
   npm verb addRemoteTarball [ 'https://registry.npmjs.org/gulp/-/gulp-3.9.0.tgz',
   npm verb addRemoteTarball   'cf1fba4cb558bb8c6ae6c9613f583ae2620d214a' ]
   npm http 304 https://registry.npmjs.org/bootstrap-sass
   npm verb etag https://registry.npmjs.org/bootstrap-sass from cache
   npm verb get saving bootstrap-sass to C:\Users\hjort\AppData\Roaming\npm-cache\registry.npmjs.org\bootstrap-sass\.cache.json
   npm verb addNamed "3.3.2" is a plain semver version for laravel-elixir
   npm verb addNamed "3.3.5" is a plain semver version for bootstrap-sass
   npm verb addRemoteTarball https://registry.npmjs.org/laravel-elixir/-/laravel-elixir-3.3.2.tgz not in flight; adding
   npm verb addRemoteTarball [ 'https://registry.npmjs.org/laravel-elixir/-/laravel-elixir-3.3.2.tgz',
   npm verb addRemoteTarball   'bc72a362ed0233a2d14985327e4a7d8a42781e6c' ]
   npm verb addRemoteTarball https://registry.npmjs.org/bootstrap-sass/-/bootstrap-sass-3.3.5.tgz not in flight; adding
   npm verb addRemoteTarball [ 'https://registry.npmjs.org/bootstrap-sass/-/bootstrap-sass-3.3.5.tgz',
   npm verb addRemoteTarball   '89f213751ee01cde0dc1f63a51e9b3521dd20ebc' ]
   npm http 304 https://registry.npmjs.org/laravel-elixir-css-url-adjuster
   npm verb etag https://registry.npmjs.org/laravel-elixir-css-url-adjuster from cache
   npm verb get saving laravel-elixir-css-url-adjuster to C:\Users\hjort\AppData\Roaming\npm-cache\registry.npmjs.org\laravel-elixir-css-url-adjuster\.cache.json
   npm verb addNamed "3.0.0" is a plain semver version for laravel-elixir-css-url-adjuster
   npm verb addRemoteTarball https://registry.npmjs.org/laravel-elixir-css-url-adjuster/-/laravel-elixir-css-url-adjuster-3.0.0.tgz not in flight; adding
   npm verb addRemoteTarball [ 'https://registry.npmjs.org/laravel-elixir-css-url-adjuster/-/laravel-elixir-css-url-adjuster-3.0.0.tgz',
   npm verb addRemoteTarball   'f92d5c673cde60c48a3048d2bd91eeb2ce02d50a' ]

1 个答案:

答案 0 :(得分:2)

你的npm版本或临时目录可能有问题 - 在npm GitHub上有一个类似的问题 - https://github.com/npm/npm/issues/7590

检查.npmrc中是否设置了两个临时目录:

npm config ls -l

查找定义tmp配置变量的行。如果您找到多个,请删除其中一个。

同时尝试将您的npm版本更新为最新版本。