summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1d02a00)
raw | patch | inline | side by side (parent: 1d02a00)
author | Pascal Obry <pascal@obry.net> | |
Mon, 6 Sep 2010 18:12:11 +0000 (20:12 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 7 Sep 2010 00:31:06 +0000 (17:31 -0700) |
The new command line parameter --smtp-server-option or default
configuration sendemail.smtpserveroption can be used to pass
specific options to the SMTP server. Update the documentation
accordingly.
Signed-off-by: Pascal Obry <pascal@obry.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
configuration sendemail.smtpserveroption can be used to pass
specific options to the SMTP server. Update the documentation
accordingly.
Signed-off-by: Pascal Obry <pascal@obry.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/config.txt | patch | blob | history | |
Documentation/git-send-email.txt | patch | blob | history | |
git-send-email.perl | patch | blob | history |
index cda6721013ac3f01e7a3b6a7e770266852cef131..bb8db24c6fb048d15f168f6ca8d4fa918efd39a9 100644 (file)
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
sendemail.smtpdomain::
sendemail.smtpserver::
sendemail.smtpserverport::
+sendemail.smtpserveroption::
sendemail.smtpuser::
sendemail.thread::
sendemail.validate::
index c283084272090c28d5529d200a1147c9f57c639b..cde404a461fc80a97d3af392eb8520b6361a5118 100644 (file)
are also accepted. The port can also be set with the
'sendemail.smtpserverport' configuration variable.
+--smtp-server-option=<option>::
+ If set, specifies the outgoing SMTP server option to use.
+ Default value can be specified by the 'sendemail.smtpserveroption'
+ configuration option.
++
+The --smtp-server-option option must be repeated for each option you want
+to pass to the server. Likewise, different lines in the configuration files
+must be used for each option.
+
--smtp-ssl::
Legacy alias for '--smtp-encryption ssl'.
diff --git a/git-send-email.perl b/git-send-email.perl
index 39cb5afe2853739102c75eacb048a847d5de1ef3..47989fe6dd1d2bb7d477a60a989805cb769d2a3c 100755 (executable)
--- a/git-send-email.perl
+++ b/git-send-email.perl
--envelope-sender <str> * Email envelope sender.
--smtp-server <str:int> * Outgoing SMTP server to use. The port
is optional. Default 'localhost'.
+ --smtp-server-option <str> * Outgoing SMTP server option to use.
--smtp-server-port <int> * Outgoing SMTP server port.
--smtp-user <str> * Username for SMTP-AUTH.
--smtp-pass <str> * Password for SMTP-AUTH; not necessary.
# Variables with corresponding config settings
my ($thread, $chain_reply_to, $suppress_from, $signed_off_by_cc, $cc_cmd);
-my ($smtp_server, $smtp_server_port, $smtp_authuser, $smtp_encryption);
+my ($smtp_server, $smtp_server_port, @smtp_server_options);
+my ($smtp_authuser, $smtp_encryption);
my ($identity, $aliasfiletype, @alias_files, $smtp_domain);
my ($validate, $confirm);
my (@suppress_cc);
my %config_settings = (
"smtpserver" => \$smtp_server,
"smtpserverport" => \$smtp_server_port,
+ "smtpserveroption" => \@smtp_server_options,
"smtpuser" => \$smtp_authuser,
"smtppass" => \$smtp_authpass,
"smtpdomain" => \$smtp_domain,
"no-bcc" => \$no_bcc,
"chain-reply-to!" => \$chain_reply_to,
"smtp-server=s" => \$smtp_server,
+ "smtp-server-option=s" => \@smtp_server_options,
"smtp-server-port=s" => \$smtp_server_port,
"smtp-user=s" => \$smtp_authuser,
"smtp-pass:s" => \$smtp_authpass,
}
}
+ unshift (@sendmail_parameters, @smtp_server_options);
+
if ($dry_run) {
# We don't want to send the email.
} elsif ($smtp_server =~ m#^/#) {