summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Smith <luke@lukesmith.xyz>2021-07-07 21:42:53 -0400
committerGitHub <noreply@github.com>2021-07-07 21:42:53 -0400
commitc8bbef5b88e0ac1b19ef712651318a968fc32f4a (patch)
treeecae385ce21d7fd275e3477848a74a3d4a99d5b4
parentf92000e5ed8d393de8f02093afebdb5ab69a1861 (diff)
parent8171e6327c2c1b4088da441ced4186d0934bc888 (diff)
Merge pull request #735 from phirecc/hostname
Set hostname variable
-rwxr-xr-xbin/mw2
1 files changed, 2 insertions, 0 deletions
diff --git a/bin/mw b/bin/mw
index d960b7b..0fd01d8 100755
--- a/bin/mw
+++ b/bin/mw
@@ -91,6 +91,7 @@ set folder = \"$folder\"
set header_cache = $cachedir/$fulladdr/headers
set message_cachedir = $cachedir/$fulladdr/bodies
set mbox_type = Maildir
+set hostname = \"$hostname\"
$extra
bind index,pager gg noop
@@ -193,6 +194,7 @@ askinfo() { \
read -r smtp
[ "$sport" = 465 ] && tlsline="tls_starttls off"
[ -z "$realname" ] && realname="${fulladdr%%@*}"
+ hostname="$(echo "$fulladdr" | cut -d @ -f 2)"
login="${login:-$fulladdr}"
if [ -n "${password+x}" ]; then
createpass