Created
December 10, 2015 18:03
-
-
Save gfldex/d31705b4478c87eb3467 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PROCESS::<$SCHEDULER> = ThreadPoolScheduler.new(initial_threads => 0, max_threads => 2); | |
my $source-dir = '../../doc/doc/'; | |
sub MAIN () { | |
put await do start { .&parse-pod-file } for sort find-pod-files $source-dir; | |
} | |
sub find-pod-files ($dir) { | |
gather for dir($dir) { | |
take .Str if .extension ~~ rx:i/pod$/; | |
take slip find-pod-files $_ if .d; | |
} | |
} | |
sub parse-pod-file ($f) { | |
put "processing $f"; | |
my $pod = (EVAL ($f.IO.slurp ~ "\n\$=pod")); | |
$pod.perl; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment