Permalink
Browse files

invalidate: quiet mode

  • Loading branch information...
ysth committed Dec 9, 2012
1 parent 4281365 commit 9cd317c245a6529777cef224441d9eefd4746fe4
Showing with 3 additions and 1 deletion.
  1. +3 −1 invalidate.pl
View
@@ -18,11 +18,13 @@
my $config_name = "config.json";
my @body_names;
my @types;
+my $quiet;
GetOptions(
"config=s" => \$config_name,
"body|b=s" => \@body_names,
"type|name=s" => \@types,
+ "quiet" => \$quiet,
) or die "$0 --config=foo.json --body=Bar\n";
my $client = Client->new(config => $config_name);
@@ -56,7 +58,7 @@
for my $body_id (@body_ids) {
for my $type (@types) {
- emit("Invalidating $type", $body_id);
+ emit("Invalidating $type", $body_id) if !$quiet;
$client->cache_invalidate(type => $type, id => $body_id);
}
}

0 comments on commit 9cd317c

Please sign in to comment.