diff options
author | Nicholas Clark <nick@ccl4.org> | 2011-12-13 15:16:37 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2011-12-19 13:55:18 +0100 |
commit | 5a6ebf5f1bade18766ab23840c650c33987032be (patch) | |
tree | b0c395e944c36ed23330aac0ddc8da3efe06e495 /installman | |
parent | e974216454f8721c048be4f1c4a1100ad8193791 (diff) | |
download | perl-5a6ebf5f1bade18766ab23840c650c33987032be.tar.gz |
installman only needs match =head1 to identify files with Pod.
Commit 63fae90782a9851d made installman skip files which contained no Pod.
However, the regex used, /^=(?:head\d+|item|pod)\b/ is overly permissive.
All files with Pod actually match /^=head1\b/. Moreover, a Pod file which
does not start with a =head1 is not going to generate a well formed man
page. Hence restrict the files processed to those which are well formed.
Diffstat (limited to 'installman')
-rwxr-xr-x | installman | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/installman b/installman index 2c20790def..ef1470a1b4 100755 --- a/installman +++ b/installman @@ -157,7 +157,7 @@ sub pod2man { local $_; while (<T>) { - ++$has_pod and last if /^=(?:head\d+|item|pod)\b/; + ++$has_pod and last if /^=head1\b/; } close T; @@ -223,3 +223,10 @@ sub rename { link($from,$to) || return 0; unlink($from); } + +# Local variables: +# cperl-indent-level: 4 +# indent-tabs-mode: nil +# End: +# +# ex: set ts=8 sts=4 sw=4 et: |