I have a simple web site using Rails 3.2. It's just a layout, a few views, some CSS, and very little JavaScript.
I'd like to generate static HTML files for the output of every URL in my site, and I'd like to dump them into some directory outside of my Rails project directory. So I'll have
[target directory]/index.html
[target directory]/products/my-category-1/index.html
[target directory]/products/my-category-2/index.html
[target directory]/products/my-category-3/index.html
[target directory]/products/my-category-1/my-product-1.html
[target directory]/products/my-category-1/my-product-2.html
[target directory]/products/my-category-1/my-product-3.html
[target directory]/products/my-category-2/my-product-1.html
[target directory]/products/my-category-2/my-product-2.html
[target directory]/products/my-category-2/my-product-3.html
[target directory]/products/my-category-3/my-product-1.html
[target directory]/products/my-category-3/my-product-2.html
[target directory]/products/my-category-3/my-product-3.html
Is there a gem or technique I can use for this?
Or maybe I should create a rake task which does a wget on each URL and writes the output to a target directory? I will have to also ensure CSS and JS files are also pulled down and included in the target directory.