1

I keep getting the error saying that the application.css isn't compiled.

I tried:

rake assets:precompile

And it didn't work, I even tried to run it with RAILS_ENV=production and still it didnt' work.

When I change my production.rb and set the config.assets.compile = true then it worked.

WHy isn't the manual compiling working?

Richard Hulse
  • 10,383
  • 2
  • 33
  • 37
Blankman
  • 259,732
  • 324
  • 769
  • 1,199

1 Answers1

1

This is a great RailsGuide on the Asset Pipeline:

http://guides.rubyonrails.org/asset_pipeline.html

you need to set RAILS_ENV before running "precompile", e.g.:

RAILS_ENV=production bundle exec rake assets:precompile

See also:

rake assets:precompile doesn't work (rails 3.1.1)

Rails 3.1 asset precompilation - include all javascript files

Community
  • 1
  • 1
Tilo
  • 33,354
  • 5
  • 79
  • 106