From: Frank Lichtenheld Date: Fri, 6 Apr 2007 21:52:41 +0000 (+0200) Subject: cvsimport: Improve usage error reporting X-Git-Tag: v1.5.1.1~23 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=7bf77644e70d881f407c77e6d65ebe70c90916d6;p=git.git cvsimport: Improve usage error reporting Actually tell the user what he did wrong in case of usage errors instead of only printing the general usage information. Signed-off-by: Frank Lichtenheld Signed-off-by: Junio C Hamano --- diff --git a/git-cvsimport.perl b/git-cvsimport.perl index d3fbcbc15..ac74bc51b 100755 --- a/git-cvsimport.perl +++ b/git-cvsimport.perl @@ -32,7 +32,9 @@ $ENV{'TZ'}="UTC"; our ($opt_h,$opt_o,$opt_v,$opt_k,$opt_u,$opt_d,$opt_p,$opt_C,$opt_z,$opt_i,$opt_P, $opt_s,$opt_m,$opt_M,$opt_A,$opt_S,$opt_L, $opt_a); my (%conv_author_name, %conv_author_email); -sub usage() { +sub usage(;$) { + my $msg = shift; + print(STDERR "Error: $msg\n") if $msg; print STDERR <