diff --git a/bin/cpan-outdated b/bin/cpan-outdated index ff2e006..43fe7ec 100644 --- a/bin/cpan-outdated +++ b/bin/cpan-outdated @@ -22,6 +22,8 @@ Getopt::Long::Configure("bundling"); Getopt::Long::GetOptions( 'h|help' => \my $help, 'verbose' => \my $verbose, + 'p|pkg=s' => \my $just_this_pkg, + 'f|filter-pkg=s' => \my $filter_pkg, 'compare-changes' => \my $compare_changes, 'm|mirror=s' => \$mirror, 'I=s' => sub { die "this option was deprecated" }, @@ -58,6 +60,8 @@ sub main { my %seen; while (my $line = <$fh>) { my ($pkg, $version, $dist) = split /\s+/, $line; + next if $just_this_pkg && $just_this_pkg ne $pkg; + next if $filter_pkg && $pkg !~ m/$filter_pkg/; next if $version eq 'undef'; next if $dist =~ m{/perl-[0-9._]+\.tar\.gz$}; (my $file = $pkg) =~ s!::!/!g;