I'm a bit new to Rails, so far so good. The assets pipeline/sprockets is pretty neat but I'm a bit confused. When generating scaffolding for my various controllers, individual css/SCSS files were put into app/assets/stylesheets. But for my project I'm using LESS not SCSS, so I replaced them with .css.less files.
The problem I'm running into is that if I add CSS to a controller (let's call it "home.css.less" for example), it gets included in every view, not just views belonging to the "home" controller. If I remove "*= require_tree ." from the application.css file, then the file's not included in any views.
How can I specify CSS code for a particular controller/view using the Rails assets pipeline?
application.css:
/*
*= require twitter/bootstrap
*= require_self
*= require "application_custom"
*/
home.css.less:
body {
background: asset-url("circles.png") no-repeat;
}
The above results in no background being applied, even to the home controller's views.