我在两种不同的npm包上都犯了同样的错误,似乎还没能弄清楚。我已经检查了this答案,并且没有任何其他服务器在运行。我还试着删除我的module_packages文件夹,清理npm cache clean,然后按照许多线程的建议使用npm i重新安装,但是我仍然得到相同的错误。
C:\Users\hunter\Documents\vid>npm install npm install github:storj/node-libstorj --save
> storj@5.1.0 preinstall C:\Users\hunter\Documents\vid\node_modules\storj
> node ./download.js
Unable to download libstorj for platform: win32 and arch: x64
npm WARN vid@1.0.0 No repository field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! storj@5.1.0 preinstall: `node ./download.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the storj@5.1.0 preinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\hunter\AppData\Roaming\npm-cache\_logs\2018-03-25T15_44_06_578Z-debug.log任何可能导致错误的想法都是有帮助的。
发布于 2018-03-25 16:45:59
我有好消息和坏消息要告诉你。好消息首先:你的电脑万事俱备。
坏消息是:您想安装的模块与windows操作系统不兼容。查看错误消息的第一行:
Unable to download libstorj for platform: win32 and arch: x64对于GitHub上的这个问题,已经有一个悬而未决的问题,请参阅:https://github.com/Storj/node-libstorj/issues/43
正如在这个问题中提到的,有许多问题:
因此,您有两个选择:等待此问题得到解决或切换您的操作系统;)
发布于 2020-06-29 12:54:43
我收到了一个“代码ELIFECYCLE”错误,试图通过package.json中的脚本条目运行"usemin“和"imagemin”节点模块。这些脚本条目是在一个课程中提供的“完整堆栈开发人员”课程:"imagemin img/* -o dist/img/ && usemin“:"usemin index.html -d dist -o dist/index.html",
第一行应改为:"imagemin -out-dir=dist/img/ img/**/*.{png,jpg,git}“
而usemin给出“代码ELIFECYLE”错误的问题最终被追溯到我已经安装了API版本("npm安装usemin")而不是cli版本("npm install usemin-cli“)。
希望上面的这些能帮助其他一些小傻瓜避免那些现在看起来很明显的错误!
https://stackoverflow.com/questions/49477845
复制相似问题