【发布时间】:2014-04-16 02:37:30
【问题描述】:
我在 Mac OS X 10.9.2 上使用 npm v1.4.4 和 node v0.10.25。
我最近升级了 node 和 npm,现在npm install 不再在 node_modules 中创建 .bin 目录。
我已删除 node_modules,再次尝试npm install,但从未创建目录和二进制文件。
有人知道为什么会这样吗?
这是我的package.json:
{
"name": "redacted",
"author": {},
"description": "redacted",
"dependencies": {
},
"devDependencies": {
"karma": "*",
"karma-coverage": "0.1.2",
"karma-junit-reporter": "*",
"karma-coffee-preprocessor": "~0.1",
"grunt": "^0.4.2",
"grunt-contrib-requirejs": "^0.4.3",
"grunt-contrib-concat": "^0.3.0",
"grunt-contrib-sass": "^0.7.2",
"grunt-contrib-htmlmin": "^0.2.0",
"grunt-contrib-cssmin": "^0.7.0",
"grunt-contrib-coffee": "^0.10.1",
"grunt-contrib-uglify": "^0.3.3",
"grunt-contrib-jst": "^0.5.1",
"grunt-contrib-qunit": "^0.4.0",
"grunt-contrib-jshint": "^0.8.0",
"grunt-contrib-watch": "^0.5.3",
"grunt-contrib-jasmine": "^0.6.1",
"grunt-contrib-compress": "^0.6.1",
"grunt-contrib-handlebars": "^0.6.1",
"grunt-contrib-less": "^0.9.0",
"grunt-contrib": "^0.9.0"
}
}
【问题讨论】:
-
你能分享你的
package.json吗? -
我已更新问题以包含 package.json 内容。
-
快速破解:
ls node_modules | xargs -n1 npm install -
我遇到了这个问题,因为我的磁盘内存已满
-
您找到解决方案了吗?在 Jenkins 构建期间运行调用
npm install时遇到此问题。构建代理是一个 Docker 容器,在从主机挂载的目录中调用npm install。这些因素中的任何一个是否会导致node_modules/.bin创建静默失败?