Skip to content

Instantly share code, notes, and snippets.

@vesan
Forked from masterkain/routes.rake
Created August 22, 2016 07:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vesan/4ebe28899c05b80a50dd4a06202ea5cc to your computer and use it in GitHub Desktop.
Save vesan/4ebe28899c05b80a50dd4a06202ea5cc to your computer and use it in GitHub Desktop.
Journey + Graphviz
namespace :routes do
desc "Writes doc/routes.html. Requires Graphviz (dot)"
task :visualizer => :environment do
File.open(Rails.root.join('doc', 'routes.html'), 'wb') do |f|
f.write Rails.application.routes.router.visualizer
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment