summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRyan Anderson <ryan@michonline.com>2006-02-02 16:56:06 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-02-03 01:52:51 (GMT)
commit30d08b34aa268e3bd4c93fa712e2eac66f1a15b3 (patch)
tree57d8077122e353f11722113bf3931ff8251fd8d1
parentd366c7037679794edff38cdbc422997607aca5f1 (diff)
downloadgit-30d08b34aa268e3bd4c93fa712e2eac66f1a15b3.zip
git-30d08b34aa268e3bd4c93fa712e2eac66f1a15b3.tar.gz
git-30d08b34aa268e3bd4c93fa712e2eac66f1a15b3.tar.bz2
git-send-email: Add --quiet to reduce some of the chatter when sending emails.
Signed-off-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
-rwxr-xr-xgit-send-email.perl9
1 files changed, 6 insertions, 3 deletions
diff --git a/git-send-email.perl b/git-send-email.perl
index 51b7513..2977b9a 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -34,7 +34,7 @@ my $compose_filename = ".msg.$$";
my (@to,@cc,$initial_reply_to,$initial_subject,@files,$from,$compose);
# Behavior modification variables
-my ($chain_reply_to, $smtp_server) = (1, "localhost");
+my ($chain_reply_to, $smtp_server, $quiet) = (1, "localhost", 0);
# Example reply to:
#$initial_reply_to = ''; #<20050203173208.GA23964@foobar.com>';
@@ -51,6 +51,7 @@ my $rc = GetOptions("from=s" => \$from,
"chain-reply-to!" => \$chain_reply_to,
"smtp-server=s" => \$smtp_server,
"compose" => \$compose,
+ "quiet" => \$quiet,
);
# Now, let's fill any that aren't set in with defaults:
@@ -267,8 +268,10 @@ sub send_message
sendmail(%mail) or die $Mail::Sendmail::error;
- print "OK. Log says:\n", $Mail::Sendmail::log;
- print "\n\n"
+ unless ($quiet) {
+ print "OK. Log says:\n", $Mail::Sendmail::log;
+ print "\n\n"
+ }
}