Skip to content

Commit

Permalink
Tidy purge script
Browse files Browse the repository at this point in the history
  • Loading branch information
rwstauner committed Jul 6, 2015
1 parent 8458b4c commit d43df67
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions bin/purge.pl
Expand Up @@ -30,8 +30,9 @@ =head1 DESCRIPTION
'purge.pl %o',
[ 'all', "purge all", ],
[ 'key|k=s@', "key(s) to purge", ],
[ 'list|l', 'list available cache keys' ],
[], [ 'help', "print usage message and exit" ],
[ 'list|l', 'list available cache keys' ],
[],
[ 'help', "print usage message and exit" ],
);

print( $usage->text ), exit if $opt->help;
Expand All @@ -42,12 +43,11 @@ =head1 DESCRIPTION
$c->cdn_purge_all();

}
elsif( $opt->list ){
elsif ( $opt->list ) {
## no critic (MutatingList)
print
grep { !/_cache_key_for_user/ }
map { s/\A.+:\s+\$c->add_surrogate_key\((.+?)\);\Z/$1/; $_ }
qx{git grep add_surrogate_key lib/MetaCPAN/Web/Controller/}
print grep { !/_cache_key_for_user/ }
map { s/\A.+:\s+\$c->add_surrogate_key\((.+?)\);\Z/$1/; $_ }
qx{git grep add_surrogate_key lib/MetaCPAN/Web/Controller/};
}
else {

Expand Down

0 comments on commit d43df67

Please sign in to comment.