Debian Codegraph @

maint/generate-readme

raw
1 #!/usr/bin/env perl
2
3 use strict;
4 use warnings;
5 use Pod::Abstract;
6 use Pod::Simple::Text;
7
8 my $root = Pod::Abstract->load_file("lib/FFI/Platypus.pm");
9
10 foreach my $name (qw( SUPPORT CONTRIBUTING ))
11 {
12 my($pod) = $root->select("/head1[\@heading=~{$name}]");
13 $_->detach for $pod->select('//#cut');
14 my $parser = Pod::Simple::Text->new;
15 my $text;
16 $parser->output_string( \$text );
17 $parser->parse_string_document( $pod->pod );
18
19 open my $fh, '>', $name;
20 print $fh $text;
21 close $fh;
22 }
23