我试图在全局范围内安装gulp,但是v8标记依赖项存在问题,可能还有更多问题。不,它告诉我。 当我尝试sudo npm install -g gulp启动过程但在某些时候失败,显示:
> v8flags@1.0.1 install /usr/local/lib/node_modules/gulp/node_modules/v8flags
> node fetch.js
sh: 1: node: not found
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian
npm http GET https://registry.npmjs.org/end-of-stream
npm http GET https://registry.npmjs.org/sequencify
npm http GET https://registry.npmjs.org/stream-consume
npm ERR! Error: ENOENT, lstat '/usr/local/lib/node_modules/gulp/node_modules/gulp-util/lib/linefeed.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/nicolas/npm-debug.log npm
npm ERR! System Linux 3.11.0-26-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "gulp"
npm ERR! cwd /home/nicolas
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.2.18
npm ERR! path /usr/local/lib/node_modules/gulp/node_modules/gulp-util/lib/linefeed.js
npm ERR! fstream_path /usr/local/lib/node_modules/gulp/node_modules/gulp-util/lib/linefeed.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! Error: ENOENT, chown '/usr/local/lib/node_modules/gulp/node_modules/liftoff/lib/find_config.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/nicolas/npm-debug.log npm
npm ERR! System Linux 3.11.0-26-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "gulp"
npm ERR! cwd /home/nicolas
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.2.18
npm ERR! path /usr/local/lib/node_modules/gulp/node_modules/liftoff/lib/find_config.js
npm ERR! fstream_path /usr/local/lib/node_modules/gulp/node_modules/liftoff/lib/find_config.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call chown
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:305:19
npm ERR! fstream_stack /usr/lib/nodejs/graceful-fs/polyfills.js:133:7
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! error rolling back Error: ENOTEMPTY, rmdir '/usr/local/lib/node_modules/gulp/node_modules/minimist/test'
npm ERR! error rolling back gulp@3.8.10 { [Error: ENOTEMPTY, rmdir '/usr/local/lib/node_modules/gulp/node_modules/minimist/test']
npm ERR! error rolling back errno: 53,
npm ERR! error rolling back code: 'ENOTEMPTY',
npm ERR! error rolling back path: '/usr/local/lib/node_modules/gulp/node_modules/minimist/test' }
npm ERR! v8flags@1.0.1 install: `node fetch.js`
npm ERR! `sh "-c" "node fetch.js"` failed with 127
npm ERR!
npm ERR! Failed at the v8flags@1.0.1 install script.
npm ERR! This is most likely a problem with the v8flags package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node fetch.js
npm ERR! You can get their info via:
npm ERR! npm owner ls v8flags
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.11.0-26-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "gulp"
npm ERR! cwd /home/nicolas
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.2.18
npm ERR! code ELIFECYCLE
npm ERR! Error: ENOENT, lstat '/usr/local/lib/node_modules/gulp/node_modules/semver/semver.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/nicolas/npm-debug.log npm
npm ERR! System Linux 3.11.0-26-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "gulp"
npm ERR! cwd /home/nicolas
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.2.18
npm ERR! path /usr/local/lib/node_modules/gulp/node_modules/semver/semver.js
npm ERR! fstream_path /usr/local/lib/node_modules/gulp/node_modules/semver/semver.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34