From: Junio C Hamano Date: Wed, 20 Mar 2024 16:04:17 +0000 (-0700) Subject: Meta/cook: notice an unused extra command line arg and fail X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=11f2323bdc8798be15d59b271d2a9d8076f03888;p=thirdparty%2Fgit.git Meta/cook: notice an unused extra command line arg and fail --- diff --git a/cook b/cook index 6d26975f29..e1d9e6aba9 100755 --- a/cook +++ b/cook @@ -1110,6 +1110,9 @@ if ($wildo) { wildo($fd); } elsif ($havedone) { havedone(); +} elsif (@ARGV) { + print STDERR "$0 does not take extra args: @ARGV\n"; + exit 1; } else { doit(); }