diff options
author | Trent Piepho <xyzzy@speakeasy.org> | 2009-05-12 15:48:56 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-05-13 20:54:57 -0700 |
commit | 09caa24facae88e19cce1c12f21dac935cbf0909 (patch) | |
tree | 73600eaea9062c2fb5b175400857b2ec22f61de8 /git-send-email.perl | |
parent | f01f1099f40f24fe6f7802185340a6fa3a3d4f35 (diff) | |
download | git-09caa24facae88e19cce1c12f21dac935cbf0909.tar.gz git-09caa24facae88e19cce1c12f21dac935cbf0909.tar.xz |
send-email: Add config option for sender address
The sender address, as specified with the '--from' command line option,
couldn't be set in the config file. So add a new config option,
'sendemail.from', which sets it. One can use 'sendemail.<identity>.from'
as well of course, which is likely the more useful case.
The sender address would default to GIT_AUTHOR_IDENT, which is usually the
right thing, but this doesn't allow switching based on the identity
selected. It's possible to switch the SMTP server and envelope sender by
using the '--identity' option, in which case one probably wants to use a
different from address as well, but this had to be manually specified.
The documentation for 'from' is also corrected somewhat. If '--from' is
specified (or the new sendemail.from option is used) then the user isn't
prompted. The default with no '--from' option (or sendemail.from option)
is GIT_AUTHOR_IDENT first then GIT_COMMITTER_IDENT, not just
GIT_COMMITTER_IDENT.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-send-email.perl')
-rwxr-xr-x | git-send-email.perl | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/git-send-email.perl b/git-send-email.perl index cccbf4517..d9c7f32aa 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -210,6 +210,7 @@ my %config_settings = ( "envelopesender" => \$envelope_sender, "multiedit" => \$multiedit, "confirm" => \$confirm, + "from" => \$sender, ); # Handle Uncouth Termination |