Well, this has been quite the read.
As a plain text person (aren't we all?) I find poor quality mail clients
annoying, as shown by the motivating screenshot of a plain text hard
folder message presenting on a narrow portrait mode mail reader.
There seem to two approaches available: `format=flowed` which works well
if the mail reader supports it, and HTML which is a PITA to author for
us.
Having just got my `format=flowed` stuff working again after being
broken for a long time, and have been using some Discourse forums
recently (via email) which accept MarkDown, I've been filled with
enthusiasm for MarkDown email. And markdown's a decent source for basic
HTML, since it's authoring overhead is low and it is very readable in
its raw form.
So I've revisited the manual and found the `$send_multipart_alternative`
option and its friend `$send_multipart_alternative_filter`. They work
well!
So now I have a mechanism to send: `format=flowed` MarkDown with a
aparallel HTML alternative. The HTML should render in a "paragraphy" way
for the HTML people, and the MarkDown keeps me happy.
My default setting is now:
set send_multipart_alternative=no
set send_multipart_alternative_filter='echo text/html; echo; exec md2html'
which is the inactive form, and I've added:
message-hook . 'set send_multipart_alternative=no'
message-hook '%f htmlees' 'set send_multipart_alternative=no'
which will be turning it on for people in my (empty so far) "htmlees"
mutt group. I use a similar pattern (`%htmlers`) for preserring HTML
over plain text for certain messages.
The `md2html` script is my personal script, which wraps `pandoc` and
post munges the HTML to indent the code blocks, which `pandoc`'s HTML
does not please my eye. It's here:
https://github.com/cameron-simpson/css/blob/main/bin-cs/md2html
if anyone wants a starting point.
I'm probably going to bind a key to turn this mode on at some point.
Cheers,
Cameron Simpson <c...@cskk.id.au>