summaryrefslogtreecommitdiff
path: root/Porting/manicheck
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2003-07-27 18:29:16 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2003-07-27 18:29:16 +0000
commitbd6c346e4e3690246a860f9d51da416c9ee28c92 (patch)
treeae83268824d4c104eb3fea37ab3b9bf3951d3b74 /Porting/manicheck
parent566ece0335f7c1c203117322dd2c63793a5c0397 (diff)
downloadperl-bd6c346e4e3690246a860f9d51da416c9ee28c92.tar.gz
Add -l (one file per line) option to manicheck.
p4raw-id: //depot/perl@20236
Diffstat (limited to 'Porting/manicheck')
-rw-r--r--Porting/manicheck14
1 files changed, 10 insertions, 4 deletions
diff --git a/Porting/manicheck b/Porting/manicheck
index e2a33ec678..9ba83606fc 100644
--- a/Porting/manicheck
+++ b/Porting/manicheck
@@ -22,14 +22,15 @@ use strict;
sub help {
die <<EOF;
-$0: Usage: $0 [-x|-m|-h]
+$0: Usage: $0 [-x|-m|-l|-h]
-x show only the extra files
-m show only the missing files
+-l show the files one per line instead of one line
-h show only this help
EOF
}
-use vars qw($x $m $h);
+use vars qw($x $m $l $h);
help() if $h;
@@ -73,8 +74,13 @@ for (sort keys %mani) {
push @miss, $_ unless $find{$_};
}
-printf("%s@xtra\n", $x || $m ? "" : "extra: ") if @xtra && !$m;
-printf("%s@miss\n", $x || $m ? "" : "missing: ") if @miss && !$x;
+$" = "\n" if $l;
+
+unshift @xtra, "extra:" if @xtra;
+unshift @miss, "missing:" if @miss;
+
+print "@xtra\n", if @xtra && !$m;
+print "@miss\n" if @miss && !$x;
exit 0;