Re: git-send-email: smtpserver in $HOME

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jan “Khardix” Staněk  <khardix@xxxxxxxxx> writes:

> Would it be feasible to treat the `smtpserver` as path option
> and expand `~`/`~user` paths?
> Would it break anything
> (i.e., is `~` a valid character for beginning of a hostname)?

I haven't given too much thought, but offhand do not think of a
reason why a change like the attached would break things.



 git-send-email.perl | 2 ++
 1 file changed, 2 insertions(+)

diff --git c/git-send-email.perl w/git-send-email.perl
index 1f425c0809..ff58ac5046 100755
--- c/git-send-email.perl
+++ w/git-send-email.perl
@@ -1006,6 +1006,8 @@ sub expand_one_alias {
 		}
 	}
 	$smtp_server ||= 'localhost'; # could be 127.0.0.1, too... *shrug*
+} elsif ($smtp_server =~ /^~/) {
+	$smtp_server = glob($smtp_server);
 }
 
 if ($compose && $compose > 0) {




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux