Is it possible without having to access the website to tell rails to perform a cache of all the files within the application.html.erb page together?
I have the following code in my page:
<%= stylesheet_link_tag ‘reset’,’forms’,’layout’,’common’,’pages’, :cache => ‘_cached’ %>
This will combine everything together into a _cached.css file when the website is loaded for the first time in production mode. However, I would like for the file to be regenerated once the website is initialized.
So the steps would be
- start the rails app
- remove the existing _cached.css file
- tell rails to recreate the file based on the code within the application.html.erb file
- website is live…
Any ideas on how todo this? Can be down as a rake command or something?
After setting up a rake task that accesses the website files once the website is loaded, this works.