无法在嵌入式ruby中导入css

时间:2012-07-24 20:28:25

标签: ruby-on-rails

HIE

我试图包含@import“bootstrap”;在名为custom.css.scss

的样式表中的文件中

现在运行应用程序我得到错误:

Started GET "/static_pages/about" for 127.0.0.1 at 2012-07-24 13:23:20 -0700
Processing by StaticPagesController#about as HTML
  Rendered static_pages/about.html.erb within layouts/application (0.0ms)
Completed 500 Internal Server Error in 44ms

ActionView::Template::Error (different prefix: "C:/" and "D:/Rails/sample_app/ap
p/assets/stylesheets"
  (in D:/Rails/sample_app/app/assets/stylesheets/custom.css.scss)):
    2: <html>
    3: <head>
    4:   <title><%= full_title(yield(:title)) %></title>
    5:   <%= stylesheet_link_tag    "application", media: "all" %>
    6:   <%= javascript_include_tag "application" %>
    7:   <%= csrf_meta_tags %>
    8: </head>
  app/views/layouts/application.html.erb:5:in `_app_views_layouts_application_ht
ml_erb___106293522_33950052'


  Rendered C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/actionpack-3.2.6
/lib/action_dispatch/middleware/templates/rescues/_trace.erb (4.0ms)

请告知如何修复它。

2 个答案:

答案 0 :(得分:2)

你在标题中写的东西是什么意思,但我认为这个问题与你的WIN设置有关:https://github.com/rails/rails/issues/660

答案 1 :(得分:0)

我将应用程序移动到安装了Rails的C:\驱动器,以解决问题。