Here’s a feature of my mail client, mutt, that I wasn’t previously aware of: the ability to emulate the mail command if you invoke it with mutt -x.
This is my use-case: every so often, I want to email a bunch of people, typically for some kind of invitation thing. But I’d like to email them the same message one by one.
I don’t want to Cc them all because I know a whole lot of people who are addicted to group reply/reply to all, and also because Gmail itself is addicted to this: it interprets mutt’s Mail-Followup-To header as Reply-To, meaning if I included an email list in the Ccs and mutt has set a Mail-Followup-To to be that email list and all other recipients minus myself (it’s been told I’m subscribed to the list), all Gmail users will reply to the entire Cc list minus myself, which is exactly the reverse of what I want. And lastly, occasionally I don’t want to give them a complete list of exactly who is and isn’t privy to whatever is in this particular email.
The standard solution is then to Bcc them. But most of my social mailing lists don’t accept Bccs, some of my friends also don’t accept them, and I also have trouble remembering who I sent the mail to.
After that, the typical thing to do (on the UNIX-like commandline anyway), is something like this:
- Store the text of the message in messagebody.txt
- Store the recipient list in addresses.txt
- Run a script that goes pretty much like this:
for address in `cat addresses.txt`
do
mail -s “Some subject line” $address < messagebody.txt
done
But then the problem is that I don’t have the usual copy of the outgoing mail in my mutt outbox, because I sent it with mail, not with mutt. However, just now I checked the mutt man page, and saw this:
OPTIONS -x Emulate the mailx compose mode.
So, that means I can do this, or something equivalent to this, and get exactly the behaviour I want (mails sent one-at-a-time with the recipient’s email in the To: field and a copy left in my mutt outbox):
do
mutt -x -s “Some subject line” $address < messagebody.txt
done