【发布时间】:2015-12-14 12:44:03
【问题描述】:
我无法将我的 angular.js 应用程序部署到 Heroku。我不断收到以下错误。但是,我可以使用 grunt serve 在本地运行它或进行 grunt build。我正在使用 heroku buildpack https://github.com/adamgoldstein/heroku-buildpack-nodejs-grunt-compass 让指南针工作。如果我不使用 buildpack,我会收到警告“警告:找不到 compass 二进制文件。”
remote: Running "wiredep:app" (wiredep) task
remote: Warning: Error: bootstrap-sass-official is not installed. Try running `bower install`. Use --force to continue.
remote:
remote: Aborted due to warnings.
remote:
remote:
remote: Execution Time (2015-09-17 14:11:30 UTC)
remote: loading tasks 332ms ▇▇▇▇▇▇▇▇▇ 18%
remote: clean:dist 130ms ▇▇▇▇ 7%
remote: wiredep:app 1.4s ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 76%
remote: Total 1.9s
remote:
remote:
remote: ! Push rejected, failed to compile Node.js app
我已经通过运行 npm install 和 bower install 清理并重新安装了我的 node_modules 和 bower 包。
这是我的 bower.json 依赖列表:
"dependencies": {
"angular": "^1.3.0",
"bootstrap-sass-official": "^3.2.0",
"angular-animate": "^1.3.0",
"angular-aria": "^1.3.0",
"angular-cookies": "^1.3.0",
"angular-messages": "^1.3.0",
"angular-resource": "^1.3.0",
"angular-route": "^1.3.0",
"angular-sanitize": "^1.3.0",
"angular-touch": "^1.3.0",
"ngInfiniteScroll": "~1.2.0",
"angular-moment": "~0.9.2",
"userapp-angular": "~2.0.4",
"ui-bootstrap": "~0.12.1",
"angular-ui-router": "~0.2.13",
"modernizr": "~2.8.3",
"angular-bootstrap": "~0.13.0",
"angular-xeditable": "~0.1.9",
"ngtoast": "~1.5.2",
"restangular": "~1.5.1",
"jquery-bridget": "~1.1.0",
"angular-rangeslider": "~0.0.13",
"angular-auto-focus": "~1.0.3",
"angular-masonry": "~0.11.0",
"angular-masonry-directive": "*",
"angular-rt-popup": "~1.0.6"
},
"devDependencies": {
"angular-mocks": "^1.3.0"
},
以及我的 package.json 依赖项:
{
"name": "angularnews",
"version": "0.0.0",
"dependencies": {
"angular": "^1.3.x",
"bower": "~1.4.1",
"compass": "^0.1.1",
"express": "~4.12.3",
"generator-angular": "~0.11.1",
"generator-karma": "~1.0.0",
"grunt-cli": "~0.1.13",
"gzippo": "~0.2.0",
"morgan": "~1.5.2",
"yo": "~1.4.6"
},
"repository": {},
"devDependencies": {
"grunt": "^0.4.5",
"grunt-autoprefixer": "^2.0.0",
"grunt-concurrent": "^1.0.0",
"grunt-contrib-clean": "^0.6.0",
"grunt-contrib-compass": "^1.0.3",
"grunt-contrib-concat": "^0.5.0",
"grunt-contrib-connect": "^0.9.0",
"grunt-contrib-copy": "^0.7.0",
"grunt-contrib-cssmin": "^0.12.0",
"grunt-contrib-htmlmin": "^0.4.0",
"grunt-contrib-imagemin": "^0.9.2",
"grunt-contrib-jshint": "^0.11.0",
"grunt-contrib-uglify": "^0.7.0",
"grunt-contrib-watch": "^0.6.1",
"grunt-filerev": "^2.1.2",
"grunt-google-cdn": "^0.4.3",
"grunt-newer": "^1.1.0",
"grunt-ng-annotate": "^0.9.2",
"grunt-svgmin": "^2.0.0",
"grunt-usemin": "^3.0.0",
"grunt-wiredep": "^2.0.0",
"jshint-stylish": "^1.0.0",
"load-grunt-tasks": "^3.1.0",
"time-grunt": "^1.0.0"
},
"engines": {
"node": ">=0.10.0"
},
"scripts": {
"test": "grunt test",
"postinstall": "bower cache clean && bower install"
}
}
有什么想法吗?
【问题讨论】:
-
bower install是您安装脚本的一部分吗? -
是的,我有一个后安装,我在其中进行凉亭安装。查看更新的 package.json
-
你能发布更多的构建日志吗?
标签: angularjs node.js heroku sass compass