On Fri, Apr 28, 2017 at 02:16:08PM +0000, Grant Edwards wrote:
> So how, in the editor, do you tell Mutt that you've created a
> multipart alternative body?

Arrange for the editor to return a MIME message?  Right now if you set 
edit_headers and manual compose a MIME message, mutt wipes out the MIME 
headers and leaves the MIME parts as garbage in the single text/plain 
part.

But if mutt would examine the message returned from $editor to see 
whether it's a MIME message, and leave the structure intact if so, that 
would be a cheap way of allowing people to hook their own MIME 
composition systems in.  People could set $editor to "markdown_mime 
/path/to/real/editor %s" which would call the editor with what mutt 
passes, but create a MIME structure with the result before handing it 
back to mutt.

There's some complexity around what to do if $edit_headers is no (look 
for a minimal MIME structure with only the MIME headers and parts?), how 
to handle reedits (pass just the text/plain part back to $editor?  pass 
the whole thing including MIME parts?), etc, but better than overloading 
$sendmail.

-- 
Ed Blackman

Reply via email to