diff --git a/Build.PL b/Build.PL index 706ec77..61e68e7 100644 --- a/Build.PL +++ b/Build.PL @@ -6,7 +6,7 @@ my $builder = Module::Build->new( module_name => 'cpanspec', license => 'perl', dist_author => 'Steven Pritchard ', - dist_version => '1.62', + dist_version => '1.63', requires => { 'Archive::Tar' => 0, 'Archive::Zip' => 0, diff --git a/Changes b/Changes index 5afe7f7..7377f3e 100644 --- a/Changes +++ b/Changes @@ -1,3 +1,8 @@ +0.63 + +* Look in $name.pod for %description and Summary also. +* Avoid useless "Summary: SYNOPSIS". + 0.62 2006-03-22 * Improve auto-detection of %description and Summary. diff --git a/cpanspec b/cpanspec index 96b7e4c..5b5c4e9 100755 --- a/cpanspec +++ b/cpanspec @@ -10,10 +10,10 @@ # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # -# $Id: cpanspec,v 1.13 2006/03/23 01:57:12 stevenpritchard Exp $ +# $Id: cpanspec,v 1.14 2006/03/24 01:07:23 stevenpritchard Exp $ my $NAME="cpanspec"; -my $VERSION='1.62'; +my $VERSION='1.63'; =head1 NAME @@ -355,9 +355,11 @@ sub get_description(%) { my $path=$args{module}; $path=~s,::,/,g; - my @pmfiles=("$args{name}-$args{version}/lib/$path.pm"); + my @pmfiles=("$args{name}-$args{version}/lib/$path.pod", + "$args{name}-$args{version}/lib/$path.pm"); do { - push(@pmfiles, "$args{name}-$args{version}/$path.pm"); + push(@pmfiles, "$args{name}-$args{version}/$path.pod", + "$args{name}-$args{version}/$path.pm"); } while ($path=~s,^[^/]+/,,); push(@pmfiles, "$args{name}-$args{version}/$args{module}") if ($args{module} !~ /::/); @@ -383,7 +385,7 @@ sub get_description(%) { $description=$1; } if ($rendered=~/NAME\s*$args{module}\s[-\s]*(\S[^\n]*)/s) { - $summary=$1; + $summary=$1 if ($1 ne "SYNOPSIS"); } return($description, $summary) if (defined($description)); }