title: How can I generate a static site from a Rails project?
body: <p>I have a simple web site using Rails 3.2. It's just a layout, a few views, some CSS, and very little JavaScript.</p>
  
  <p>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</p>
  
  <pre><code>[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
  </code></pre>
  
  <p>Is there a gem or technique I can use for this?</p>
  
  <p>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.</p>