Posted at

npm ERR! peerinvalid The package generator-karma does not satisfy its siblings' peerDependencies

More than 3 years have passed since last update.


問題

express-generatorを入れようとしたら

$ npm install -g express-generator

下記のようなエラーがでた

npm ERR! peerinvalid The package generator-karma does not satisfy its siblings' peerDependencies requirements!

npm ERR! peerinvalid Peer generator-angular@0.9.2 wants generator-karma@>=0.8.2
npm ERR! peerinvalid Peer generator-angularexpress@0.0.5 wants generator-karma@~0.6.0

npm ERR! System Darwin 13.4.0

npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! code EPEERINVALID
npm ERR!
npm ERR! Additional logging details can be found in:

npm ERR! not ok code 0

依存するgenerator-karmaのバージョンが古いようです


対応

generator-karmaを消して

$ npm uninstall -g generator-karma

unbuild generator-karma@0.8.3

再実行で入れ直します

$ npm install -g express-generator

~/.npm-packages/bin/express -> ~/.npm-packages/lib/node_modules/express-generator/bin/express
express-generator@4.9.0 ~/.npm-packages/lib/node_modules/express-generator
├── commander@1.3.2 (keypress@0.1.0)
└── mkdirp@0.5.0 (minimist@0.0.8)

ok!

参考