I saw in the archives that this is a bit of an FAQ, and it seems that to
this day there's not much of an answer, sadly.

The best I could do was to create an index macro that pipes the current
message to a script that then: a) pipes stdin to formail, b) saves the
result in a tmp file, c) starts a new instance of mutt -f that_file.  Or
perhaps using -H.  But that's clearly not quite what I want, nor what
the various users who have asked for this want.

Ideas:

 - Add a function like <pipe-message> but which instead of piping the
   message puts the message in a temp file and then allows for expansion
   of several parameters in the command line, including:

    %f (the address of the sender of the message)
    %r (the To: addresses of the message)
    %c (the Cc: addresses of the message)
    %a (the To: and Cc: addresses of the message)
    %l (the To: and Cc: addresses of the message that are lists)
    %R (the Reply-To: address of the message)
    %s (the Subject: of the message, with "Re: " prefixed if not %already)
    %F (the name of the file containing the message)

 - Same as above but also provide a Unix domain socket/door/whatever
   that mutt can listen on for commands from the external command.  The
   purpose of this is to support connection sharing and avoid having to
   re-type IMAP/SMTP passwords.  The main sub-command would be to send
   the message found in a given file, and also to mark a message in a
   folder as replied.  The name of the rendezvous would be set in an
   environment variable and mutt would support using it.  All
   send/save/*-hooks would be applied in the primary mutt.

   (This is not really needed when using SASL/GSSAPI, of course.  It's
   primrarily useful when there are passwords to type.)

Where would I start if I was to try to implement the first of the above?

Nico
-- 

Reply via email to