Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
Personal perldoc webserverby Tanktalus (Canon) |
on Feb 28, 2013 at 00:49 UTC ( [id://1020979]=CUFP: print w/replies, xml ) | Need Help?? |
Most of the time I want to read the doc for a module, I either bring up konqueror where I have a shortcut "mod:" that sends me to "https://metacpan.org/module/\{@}", or I have to run "perldoc" on the module in my console because either I need the specific version of the module I'm using, and that's not always the latest, or, more likely, I need the doc to a module in our own repository (i.e., our code). Having given up on that, I whipped together the following. Now I can go to "http://localhost:8877/Module::Name" and get the perldoc in HTML form in my browser for this particular level. As a bonus, the links (L<...>) between modules works as well, which didn't quite happen for free. TODO list includes being able to dynamically switch between multiple installed perls for the @INC that I'll be using, as well as multiple code streams (getting the doc for My::Foo in the current release, the previous release, etc.), probably by allowing some sort of version identifier in the URL (http://localhost:8877/v3/My::Foo), and getting the perldoc -f flag :) In the hopes it gives someone else a starting point... And the main script is my as-always-so-short:
Update: removed reference to parent class - I don't think it's needed here.
Back to
Cool Uses for Perl
|
|