summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2022-01-07 09:49:42 +0100
committerDaniel Stenberg <daniel@haxx.se>2022-01-07 09:49:42 +0100
commit8e657c366709215de1a9525dca6ceb25244da7d9 (patch)
tree2516829e53e328e9906694e34e3a232283029749
parent30aea2b1ede1aa36429858b27c3c140e96647b29 (diff)
downloadcurl-8e657c366709215de1a9525dca6ceb25244da7d9.tar.gz
scripts/copyright.pl: hush unless -v (for verbose) is used
-rwxr-xr-xscripts/copyright.pl15
1 files changed, 11 insertions, 4 deletions
diff --git a/scripts/copyright.pl b/scripts/copyright.pl
index 3f57d21e8..9f37d1f2d 100755
--- a/scripts/copyright.pl
+++ b/scripts/copyright.pl
@@ -6,7 +6,7 @@
# | (__| |_| | _ <| |___
# \___|\___/|_| \_\_____|
#
-# Copyright (C) 1998 - 2021, Daniel Stenberg, <daniel@haxx.se>, et al.
+# Copyright (C) 1998 - 2022, Daniel Stenberg, <daniel@haxx.se>, et al.
#
# This software is licensed as described in the file COPYING, which
# you should have received as part of this distribution. The terms
@@ -154,6 +154,11 @@ sub checkfile {
}
my @all;
+my $verbose;
+if($ARGV[0] eq "-v") {
+ $verbose = 1;
+ shift @ARGV;
+}
if($ARGV[0]) {
push @all, $ARGV[0];
}
@@ -179,8 +184,10 @@ for my $f (@all) {
}
}
-print STDERR "$missing files have no copyright\n" if($missing);
-print STDERR "$wrong files have wrong copyright year\n" if ($wrong);
-print STDERR "$skiplisted files are skipped\n" if ($skiplisted);
+if($verbose) {
+ print STDERR "$missing files have no copyright\n" if($missing);
+ print STDERR "$wrong files have wrong copyright year\n" if ($wrong);
+ print STDERR "$skiplisted files are skipped\n" if ($skiplisted);
+}
exit 1 if($missing || $wrong);