Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
send-email: add option -h
author
Clemens Buchacher
<drizzd@aon.at>
Sat, 3 Sep 2011 17:06:13 +0000
(19:06 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Tue, 13 Sep 2011 00:00:23 +0000
(17:00 -0700)
Most other git commands print a synopsis when passed -h. Make
send-email do the same.
Signed-off-by: Clemens Buchacher <drizzd@aon.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-send-email.perl
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
4b5eac7
)
diff --git
a/git-send-email.perl
b/git-send-email.perl
index 98ab33aae7e35c2d288bc34ddb2bbc71f8a16cdd..734356a6fb3b22dceb4a1afe7751811628b60ce7 100755
(executable)
--- a/
git-send-email.perl
+++ b/
git-send-email.perl
@@
-275,7
+275,9
@@
sub signal_handler {
# Begin by accumulating all the variables (defined above), that we will end up
# needing, first, from the command line:
-my $rc = GetOptions("sender|from=s" => \$sender,
+my $help;
+my $rc = GetOptions("h" => \$help,
+ "sender|from=s" => \$sender,
"in-reply-to=s" => \$initial_reply_to,
"subject=s" => \$initial_subject,
"to=s" => \@initial_to,
@@
-313,6
+315,7
@@
sub signal_handler {
"force" => \$force,
);
+usage() if $help;
unless ($rc) {
usage();
}