试图让引导程序工作,它在本地服务器上,但在部署到 heroku 后,页面不会加载。我尝试将 gem 移到资产之外,但无论哪种方式,我都会遇到相同的错误。任何帮助将不胜感激
Heroku 日志
2012-09-22T21:51:41+00:00 app[web.1]: Processing by MainController#admin as HTML
2012-09-22T21:51:41+00:00 app[web.1]: Rendered main/admin.html.erb within layouts/admin (43.1ms)
2012-09-22T21:51:41+00:00 app[web.1]: 8:
2012-09-22T21:51:41+00:00 app[web.1]: Completed 500 Internal Server Error in 574ms
2012-09-22T21:51:41+00:00 app[web.1]: 10:
2012-09-22T21:51:41+00:00 app[web.1]: 12: <%= stylesheet_link_tag "tableStyle", :media => "all" %>
2012-09-22T21:51:41+00:00 app[web.1]: 11: <%= stylesheet_link_tag "bootstrap_and_overrides", :media => "all" %>
2012-09-22T21:51:41+00:00 app[web.1]:
2012-09-22T21:51:41+00:00 app[web.1]:
2012-09-22T21:51:41+00:00 app[web.1]: ActionView::Template::Error ('twitter/bootstrap/bootstrap.less' wasn't found.
2012-09-22T21:51:41+00:00 app[web.1]: (in /app/app/assets/stylesheets/bootstrap_and_overrides.css.less)):
2012-09-22T21:51:41+00:00 app[web.1]: 9: <title>Live Well Chicago L.L.C</title>
2012-09-22T21:51:41+00:00 app[web.1]: app/views/layouts/admin.html.erb:11:in `_app_views_layouts_admin_html_erb__2391414357054926185_30786800'
2012-09-22T21:51:41+00:00 app[web.1]:
2012-09-22T21:51:41+00:00 app[web.1]:
2012-09-22T21:51:41+00:00 app[web.1]: app/controllers/main_controller.rb:19:in `admin'
2012-09-22T21:51:41+00:00 app[web.1]: 13: <%= javascript_include_tag "application" %>
宝石文件
# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails', '~> 3.2.3'
gem 'coffee-rails', '~> 3.2.1'
gem 'twitter-bootstrap-rails'
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', :platform => :ruby
gem 'uglifier', '>= 1.0.3'
end
[编辑] 好吧,我已经将问题缩小到 bootstrap_and_overrides.css.less,几乎所有的导入语句
@import "twitter/bootstrap/responsive";
@import "twitter/bootstrap/responsive";
@import "fontawesome";
我有点不高兴,因为当从终端导轨运行服务器时能够检索适当的资产,但是,在部署后它不知道它们在哪里。我也不确定这些文件是否应该被隐藏,但是在我的项目文件夹中找不到“twitter”文件夹,至少它不可见