blob: 86ea610fc7b61271001af4188f06947f5dbabf81 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
This morning I saw
[[http://marcus.nordaaker.com/awesome-route-graph-with-mojoxroutesasgraph/][this
post]] from Marcus Ramberg about
[[http://search.cpan.org/perldoc?MojoX::Routes::AsGraph][MojoX::Routes::AsGraph]].
I liked the idea. But as I Catalyst instead of Mojo, I thought I could
give a try and do the same thing for Catalyst dispatcher, and I've coded
CatalystX::Dispatcher::AsGraph. For the moment only private actions are
graphed.
You use it like this:
=perl bin/catalyst_graph_dispatcher.pl --appname Arkham --output routes.png=
You can create a simple script to output as text if you prefer:
#+BEGIN_SRC perl
#!/usr/bin/perl -w
use strict;
use CatalystX::Dispatcher::AsGraph;
my $graph = CatalystX::Dispatcher::AsGraph->new_with_options();
$graph->run;
print $graph->graph->as_txt;
#+END_SRC
The code is on
[[http://git.lumberjaph.net/p5-catalystx-dispatcher-asgraph.git/][my git
server]] for the moment.
For thoses who are interested by visualization, I'll publish soon some
(at least I think) really nice visualisations about CPAN, Perl, and his
community, that we have created at [[http://rtgi.fr][$work]].
|