Rails 3: I want to list all paths defined in my rails application

One more solution is

Rails.application.routes.routes

http://hackingoff.com/blog/generate-rails-sitemap-from-routes/


rails routes | grep <specific resource name>

displays resource specific routes, if it is a pretty long list of routes.


Update

I later found that, there is an official way to see all the routes, by going to http://localhost:3000/rails/info/routes. Official docs: https://guides.rubyonrails.org/routing.html#listing-existing-routes


Though, it may be late, But I love the error page which displays all the routes. I usually try to go at /routes (or some bogus) path directly from the browser. Rails server automatically gives me a routing error page as well as all the routes and paths defined. That was very helpful :)

So, Just go to http://localhost:3000/routes enter image description here


rake routes

or

bundle exec rake routes