I am always forced to make my terminal window two dual monitors wide just to see read them right. I\'m not a stickler for buttery GUI\'s, but this is ridiculous.
Is ther
Rails 3.1 version, Replace all tag with your application name.
desc 'Pretty print out all defined routes in match order, with names. Target specific controller with CONTROLLER=x.'
task :pretty_routes => :environment do
all_routes = ENV['CONTROLLER'] ? ::Application.routes.select { |route| route.defaults[:controller] == ENV['CONTROLLER'] } : ::Application.routes
routes = all_routes.routes.collect do |route|
reqs = route.requirements.empty? ? "" : route.requirements.inspect
{:name => route.name, :verb => route.verb, :path => route.path, :reqs => reqs}
end
File.open(File.join(Rails.root, "routes.html"), "w") do |f|
f.puts "Rails 3 Routes "
f.puts "Name Verb Path Requirements "
routes.each do |r|
f.puts "#{r[:name]} #{r[:verb]} #{r[:path]} #{r[:reqs]} "
end
f.puts "
"
end
end