[merged] heiko
authorHeiko Schlittermann (JUMPER) <hs@schlittermann.de>
Sat, 11 Jan 2014 17:25:56 +0100
branchheiko
changeset 6 aafd8332d7a6
parent 3 71a0c4bd43b1 (diff)
parent 5 52faa36ba7f8 (current diff)
child 7 2bda25a39ef4
[merged]
check
--- a/check	Sat Jan 11 17:20:05 2014 +0100
+++ b/check	Sat Jan 11 17:25:56 2014 +0100
@@ -36,21 +36,25 @@
 
 exit main @ARGV;
 
-
 #----
 
 sub main {
+    my @opt_ignore;
     my $opt_verbose = 0;
 
     GetOptions(
-        'h|help' => sub { pod2usage(-verbose => 1, -exit => 0) },
-        'm|man'  => sub { pod2usage(-verbose => 2, -exit => 0) },
-        'v|verbose' => \$opt_verbose,
+        'i|ignore=s@' => \@opt_ignore,
+        'h|help'      => sub { pod2usage(-verbose => 1, -exit => 0) },
+        'm|man'       => sub { pod2usage(-verbose => 2, -exit => 0) },
+        'v|verbose'   => \$opt_verbose,
     ) or pod2usage;
 
-    if ($opt_verbose) { *::verbose = sub { say '# ', @_ } }
-    else { *::verbose = sub { } }
-
+    if ($opt_verbose) {
+        *::verbose = sub { say '# ', @_ }
+    }
+    else {
+        *::verbose = sub { }
+    }
 
     # test needs to be run as root:* or as backup:backup
     my $USER  = 'backup';
@@ -76,7 +80,7 @@
     eval { amchecks @confs } or critical $@;
 
     my @dles = eval { amlists @confs } or critical $@;
-    ok 'config: ' .join(', ', @confs), @dles;
+    ok 'config: ' . join(', ', @confs), @dles;
 
     # never reached
     return 0;
@@ -255,6 +259,10 @@
 
 =over
 
+=item B<-i>|B<--ignore> I<filesystem>
+
+The name of a filesystem to be ignored.
+
 =item B<-h>|B<--help>
 
 Show a short description and help text.