summaryrefslogtreecommitdiff
path: root/dist
diff options
context:
space:
mode:
authorAlexandr Ciornii <alexchorny@gmail.com>2013-02-18 20:03:14 +0000
committerChris 'BinGOs' Williams <chris@bingosnet.co.uk>2013-02-18 20:03:14 +0000
commitd8a821feb69cac5cb55d5dc572f80df362ba956d (patch)
treeb92c1574601a35643422790cd39017d74c1b7167 /dist
parent8a987e1a0b6f09eff1ce8186ed3e0fabb02c02b6 (diff)
downloadperl-d8a821feb69cac5cb55d5dc572f80df362ba956d.tar.gz
[perl #116809] Upstream status in corelist
First patch explains in corelist output that deprecation means that module will be CPAN-only. Second patch adds new option, -u (upstream information). Shows if module is primarily maintained in perl core or on CPAN and bug tracker URL. Module::CoreList already contains this data, only output will be added. Signed-off-by: Chris 'BinGOs' Williams <chris@bingosnet.co.uk>
Diffstat (limited to 'dist')
-rw-r--r--dist/Module-CoreList/corelist21
1 files changed, 19 insertions, 2 deletions
diff --git a/dist/Module-CoreList/corelist b/dist/Module-CoreList/corelist
index 5cd2f8cb57..fe56d975e9 100644
--- a/dist/Module-CoreList/corelist
+++ b/dist/Module-CoreList/corelist
@@ -16,6 +16,7 @@ See L<Module::CoreList> for one.
corelist [-r <PerlVersion>] ...
corelist --feature <FeatureName> [<FeatureName>] ...
corelist --diff PerlVersion PerlVersion
+ corelist --upstream <ModuleName>
=head1 OPTIONS
@@ -116,6 +117,11 @@ If you pass a perl version you get the release date for that version only.
lists the first version bundle of each named feature given
+=item --upstream, -u
+
+Shows if the given module is primarily maintained in perl core or on CPAN
+and bug tracker URL.
+
=back
As a special case, if you specify the module name C<Unicode>, you'll get
@@ -135,7 +141,7 @@ my %Opts;
GetOptions(
\%Opts,
- qw[ help|?! man! r|release:s v|version:s a! d diff|D feature|f ]
+ qw[ help|?! man! r|release:s v|version:s a! d diff|D feature|f u|upstream ]
);
pod2usage(1) if $Opts{help};
@@ -333,7 +339,7 @@ sub module_version {
$msg .= " was ";
$msg .= "first " unless $ver;
$msg .= "released with perl " . format_perl_version($ret);
- $msg .= ( $rem ? ',' : ' and' ) . " deprecated in " . format_perl_version($deprecated) if $deprecated;
+ $msg .= ( $rem ? ',' : ' and' ) . " deprecated (will be CPAN-only) in " . format_perl_version($deprecated) if $deprecated;
$msg .= " and removed from " . format_perl_version($rem) if $rem;
} else {
$msg .= " was not in CORE (or so I think)";
@@ -341,6 +347,17 @@ sub module_version {
print $msg,"\n";
+ if( defined $ret and exists $Opts{u} ) {
+ my $upsream = $Module::CoreList::upstream{$mod};
+ $upsream = 'undef' unless $upsream;
+ print "upstream: $upsream\n";
+ if ( $upsream ne 'blead' ) {
+ my $bugtracker = $Module::CoreList::bug_tracker{$mod};
+ $bugtracker = 'unknown' unless $bugtracker;
+ print "bug tracker: $bugtracker\n";
+ }
+ }
+
if(defined $ret and exists $Opts{a} and $Opts{a}){
display_a($mod);
}