2017-11-17 12:36:14 +00:00
|
|
|
diff --git a/Documentation/git-send-email.txt b/Documentation/git-send-email.txt
|
|
|
|
--- a/Documentation/git-send-email.txt
|
|
|
|
+++ b/Documentation/git-send-email.txt
|
2018-04-09 09:02:57 +01:00
|
|
|
@@ -208,8 +208,7 @@ a password is obtained using 'git-credential'.
|
2017-11-17 12:36:14 +00:00
|
|
|
specify a full pathname of a sendmail-like program instead;
|
|
|
|
the program must support the `-i` option. Default value can
|
|
|
|
be specified by the `sendemail.smtpServer` configuration
|
2018-01-18 14:13:17 +00:00
|
|
|
- option; the built-in default is to search for `sendmail` in
|
|
|
|
- `/usr/sbin`, `/usr/lib` and $PATH if such program is
|
2018-04-09 09:02:57 +01:00
|
|
|
+ option; the built-in default is to search in $PATH if such program is
|
2018-01-18 14:13:17 +00:00
|
|
|
available, falling back to `localhost` otherwise.
|
|
|
|
|
2017-11-17 12:36:14 +00:00
|
|
|
--smtp-server-port=<port>::
|
|
|
|
diff --git a/git-send-email.perl b/git-send-email.perl
|
|
|
|
--- a/git-send-email.perl
|
|
|
|
+++ b/git-send-email.perl
|
2018-04-09 09:02:57 +01:00
|
|
|
@@ -944,8 +944,7 @@ if (defined $reply_to) {
|
2017-11-17 12:36:14 +00:00
|
|
|
}
|
2018-01-18 14:13:17 +00:00
|
|
|
|
2017-11-17 12:36:14 +00:00
|
|
|
if (!defined $smtp_server) {
|
2018-01-18 14:13:17 +00:00
|
|
|
- my @sendmail_paths = qw( /usr/sbin/sendmail /usr/lib/sendmail );
|
|
|
|
- push @sendmail_paths, map {"$_/sendmail"} split /:/, $ENV{PATH};
|
2017-11-17 12:36:14 +00:00
|
|
|
+ my @sendmail_paths = map {"$_/sendmail"} split /:/, $ENV{PATH};
|
2018-01-18 14:13:17 +00:00
|
|
|
foreach (@sendmail_paths) {
|
2017-11-17 12:36:14 +00:00
|
|
|
if (-x $_) {
|
|
|
|
$smtp_server = $_;
|