RailRoad generates nice diagrams of your models and controllers.
First, you’ll have to install the plugin. Then in “lib/task” of your project create the diagrams.rake file with:
1 2 3 4 5 6 7 8 9 10 11 | namespace :doc do namespace :diagram do task :models do sh "railroad -i -l -a -m -M | dot -Tpng | sed 's/font-size:14.00/font-size:11.00/g' > doc/models.png" end task :controllers do sh "railroad -i -l -C | neato -Tpng | sed 's/font-size:14.00/font-size:11.00/g' > doc/controllers.png" end end task :diagrams => %w(diagram:models diagram:controllers) end |
Run rake doc:diagrams and voila!


