我想使用grunt-contrib-jasmine
NPM软件包。它有各种依赖。依赖图的部分看起来像这样:如何覆盖嵌套的NPM依赖项版本?
─┬ [email protected]
│ ├─┬ [email protected]
│ │ ├─┬ [email protected]
遗憾的是,在这个版本phantomjs
它禁止在Mac OS X上安装正确这是在最新版中的错误。
我怎样才能得到grunt-lib-phantomjs
使用较新版本的phantomjs
?
一些额外的背景:
grunt-contrib-jasmine
明确要求的grunt-lib-phantomjs
"~0.2.0"
版本,其中明确要求版本的phantomjs
"~1.8.1"
。- 将
phantomjs
添加到我的包的依赖关系中,首先没有任何影响;两个版本均已安装,并且grunt-contrib-jasmine
仍使用旧版本(请参阅:When installing a package with NPM, can you tell it to use a different version of one of its dependencies?)。
只需'git clone'或fork需要的模块。您也可以手动删除嵌套的'phantomjs'。 – elmigranto 2013-04-04 12:16:43
['grunt-contrib-jasmine'](https://npmjs.org/package/grunt-contrib-jasmine)在0.5.1上,它使用'grunt-lib-phantomjs @ 0.3.1',它使用' phantomjs @ 1.9.1-0' :) – gustavohenke 2013-07-02 11:40:24