0

我尝试安装derbyjs,但出现以下错误:

alex@alex-K43U:~/derby$ npm install -g derby
npm http GET https://registry.npmjs.org/derby
npm http 200 https://registry.npmjs.org/derby
npm http GET https://registry.npmjs.org/derby/-/derby-0.3.13.tgz
npm http 200 https://registry.npmjs.org/derby/-/derby-0.3.13.tgz
npm http GET https://registry.npmjs.org/dom-shim
npm http GET https://registry.npmjs.org/html-util
npm http GET https://registry.npmjs.org/tracks
npm http GET https://registry.npmjs.org/racer/0.3.13
npm http GET https://registry.npmjs.org/chokidar
npm http GET https://registry.npmjs.org/less
npm http GET https://registry.npmjs.org/up
npm http GET https://registry.npmjs.org/stylus
npm http GET https://registry.npmjs.org/mkdirp
npm http GET https://registry.npmjs.org/commander
npm http GET https://registry.npmjs.org/nib
npm http 200 https://registry.npmjs.org/dom-shim
npm http GET https://registry.npmjs.org/dom-shim/-/dom-shim-0.1.1.tgz
npm http 200 https://registry.npmjs.org/tracks
npm http GET https://registry.npmjs.org/tracks/-/tracks-0.1.8.tgz
npm http 200 https://registry.npmjs.org/html-util
npm http GET https://registry.npmjs.org/html-util/-/html-util-0.1.3.tgz
npm http 200 https://registry.npmjs.org/racer/0.3.13
npm http 200 https://registry.npmjs.org/chokidar
npm ERR! error installing derby@0.3.13
npm http GET https://registry.npmjs.org/racer/-/racer-0.3.13.tgz

npm ERR! Error: No compatible version found: chokidar@'>=0.2.6'
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR!     at installTargetsError (/home/alex/nvm/v0.6.7/lib/node_modules/npm/lib/cache.js:488:10)
npm ERR!     at next_ (/home/alex/nvm/v0.6.7/lib/node_modules/npm/lib/cache.js:438:17)
npm ERR!     at next (/home/alex/nvm/v0.6.7/lib/node_modules/npm/lib/cache.js:415:44)
npm ERR!     at /home/alex/nvm/v0.6.7/lib/node_modules/npm/lib/cache.js:408:5
npm ERR!     at saved (/home/alex/nvm/v0.6.7/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR!     at Object.oncomplete (/home/alex/nvm/v0.6.7/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js:231:7)
npm ERR! You may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>
npm ERR! 
npm ERR! System Linux 3.0.0-24-generic
npm ERR! command "node" "/home/alex/nvm/v0.6.7/bin/npm" "install" "-g" "derby"
npm ERR! cwd /home/alex/derby
npm ERR! node -v v0.6.7
npm ERR! npm -v 1.1.0-3
npm ERR! message No compatible version found: chokidar@'>=0.2.6'
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /home/alex/derby/npm-debug.log
npm not ok

我不知道如何解决这个问题。有什么建议么?

4

1 回答 1

3

查看chokidar 的package.json版本 >=0.2.6 的文件告诉我它需要 node.js 版本 0.6.10 或更高版本。您正在尝试为节点 0.6.7 安装它。

此外,我建议将 Derby 与节点 0.8.x 一起使用。至少我在节点 0.8.x 上没有安装 Derby 的问题。

于 2012-09-09T21:41:44.130 回答