diff --git a/Doc/scantree.pl b/Doc/scantree.pl index cdccc53cf..6ceb7eeb2 100644 --- a/Doc/scantree.pl +++ b/Doc/scantree.pl @@ -44,20 +44,24 @@ $outindex="$outdir/Index.pod" unless (defined $outindex); unlink $outindex if -e $outindex; # Handle read only file open my $podfh, ">", $outindex or die "couldn't open $outindex: $!"; -print $podfh <<'EOPOD'; +my $pod; -=head1 NAME +$pod = <<'EOPOD'; -PDL::Index - an index of PDL documentation + =head1 NAME -=head1 DESCRIPTION + PDL::Index - an index of PDL documentation -A meta document listing the documented PDL modules and -the PDL manual documents + =head1 DESCRIPTION -=head1 PDL manuals + A meta document listing the documented PDL modules and + the PDL manual documents + + =head1 PDL manuals EOPOD +$pod =~ s/^ //gm; +print $podfh $pod; print $podfh "=over 4\n\n"; for (@mans) { @@ -66,13 +70,15 @@ =head1 PDL manuals print $podfh "=item *\n\n$ref\n\n"; } -print $podfh <<'EOPOD'; +$pod = <<'EOPOD'; -=back + =back -=head1 PDL scripts + =head1 PDL scripts EOPOD +$pod =~ s/^ //gm; +print $podfh $pod; print $podfh "=over 4\n\n"; for (@scripts) { @@ -81,13 +87,15 @@ =head1 PDL scripts print $podfh "=item *\n\n$ref\n\n"; } -print $podfh <<'EOPOD'; +$pod = <<'EOPOD'; -=back + =back -=head1 PDL modules + =head1 PDL modules EOPOD +$pod =~ s/^ //gm; +print $podfh $pod; print $podfh "=over 4\n\n"; for (@mods) { @@ -102,15 +110,17 @@ =head1 PDL modules print $podfh "=item *\n\n$ref\n\n"; } -print $podfh <<"EOPOD"; +$pod = <<'EOPOD'; -=back + =back -=head1 HISTORY + =head1 HISTORY -Automatically generated by scantree.pl for PDL version $PDL::VERSION. + Automatically generated by scantree.pl for PDL version $PDL::VERSION. EOPOD +$pod =~ s/^ //gm; +print $podfh $pod; close $podfh;