Forum: Ruby on Rails available: google sitemap for rails project

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Raphael B. (Guest)
on 2006-04-28 16:45
(Received via mailing list)

Google Sitemaps ( is a way
to help Google's crawler on your website.

I've published a little script to generate, from a rails project, a
urllist file usable with the Google sitemap generator.

You drop the script in your RAILS_ROOT/lib directory, edit it to set
the base url, and you're set. Run it with

ruby script/runner "require 'gen_url_list'"

Download and more info in a blog post at

The script can work with controllers in subdirectories and can set the
last modification date of the url based on the last modification date
of the controller file.

 It doesn't use the Rails Routes as I didn't find how to use the
url_for method in the script ( it's a controller instance method).

Hoping this can be helpful for someone.


This topic is locked and can not be replied to.