-
Notifications
You must be signed in to change notification settings - Fork 37
not creating files in non-development mode #27
Comments
the comment is outdated. |
I would never have checked in my .css files or any generated file in a git repo. I'm pretty hardcore on this, though, I don't check in, say, jquery either, I add the jquery repo as a submodule and build it from source. So, is the current version of the plugin not creating the CSS files when the app boots in prod mode? |
Better question: does the plugin now require that you check the generated CSS into the repo? |
Grosser: ok. I generally don't like to checkin automated files (so easy for them to become outdated!), and:
BUT, for those of us that like to not check in compiled css, the answer is to include Less::More.generate_all in an initializer and call it good |
i think a better solution (in case you do not want to checkin the css) is to rake more:generate when deploying, so the modified timestamps stay the same(users do not need to load duplicated css from servers with different mtime), and you do not add more time (in our case ~8 seconds) to the per-process reboot time |
Very good point, grosser. Generating CSS belongs in "deployment", not "starting process". So in order to close this issue, the README needs to be updated :) |
hello, their is a comment in lib/less/more.rb that states:
By default, Less::More.parse will be called for each request in
development
environment and on application initialization inproduction
environment.However, this doesn't seem to be the case, and I didn't find any information that highlighted as such. Two suggestions for rails/init.rb
what do you think?
The text was updated successfully, but these errors were encountered: