Skip to content

Commit

Permalink
added pkg filter options
Browse files Browse the repository at this point in the history
  • Loading branch information
draegtun committed Sep 24, 2010
1 parent 1bcdeaf commit f708a1e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bin/cpan-outdated
Expand Up @@ -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" },
Expand Down Expand Up @@ -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;
Expand Down

0 comments on commit f708a1e

Please sign in to comment.