Removing mutt's send delay
I originally used mutt's built-in SMTP MTA. However, there is a considerable pause after hitting send. This can be disabled by using an external MTA with
set sendmail_wait=-1 in
However, if I use
msmtp as the MTA, then there is no notification of errors (although
msmtp does write to
logfile as specified in
Attempt to get notifications
From the command line, I can trigger a command when
</tmp/tosend msmtp -a default email@example.com --read-envelope-from || echo failed
Conceivably, I could mail a failure notification to my local *nix mail. However, this doesn't seem to work in mutt, if I set the following in
set sendmail = "/usr/bin/msmtp || date >> /tmp/msmtp.fail"
This causes all email to fail to send silently, with the following error in
Nov 05 10:53:09 host=mail.bar.com tls=on auth=on firstname.lastname@example.org email@example.com recipients=||,date,>>,/tmp/msmtp.fail,firstname.lastname@example.org smtpstatus=501 smtpmsg='501 #5.1.1 bad address ' errormsg='recipient address >> not accepted by the server' exitcode=EX_DATAERR
mutt is parsing the extra parts of the command as recipients.
Is there a way to get notifications of sent emails that fail, while sending in the background? I'm not tied to