【发布时间】:2011-10-13 12:28:58
【问题描述】:
app/assets/stylesheets/application.css
*= require formtastic
我收到此错误:
rake assets:precompile
/Users/Nerian/.rvm/rubies/ruby-1.9.3-rc1/bin/ruby /Users/Nerian/.rvm/gems/ruby-1.9.3-rc1@davinci/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
rake aborted!
Invalid CSS after "*": expected "{", was "= require formt..."
(in /Users/Nerian/Projects/davinci/app/assets/stylesheets/application.css)
Tasks: TOP => assets:precompile:primary
(See full trace by running task with --trace)
rake aborted!
Command failed with status (1): [/Users/Nerian/.rvm/rubies/ruby-1.9.3-rc1/b...]
所以 rake 任务不起作用,但奇怪的是,当我在开发中运行应用程序时,资产被编译,因为我可以看到正在应用的 formtastic css。
我做错了什么?
编辑:
/*
* This is a manifest file that'll automatically include all the stylesheets available in this directory
* and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
* the top of the compiled file, but it's generally better to create a new file per style scope.
*= require_self
*= require_tree .
*= require formtastic
*= require my_formtastic_changes
*/
【问题讨论】:
标签: ruby-on-rails