On Wed, May 15, 2002 at 01:15:28AM -0000, mutt-users-digest wrote:
> Date: Tue, 14 May 2002 15:07:58 -0700
> From: Michael Elkins <[EMAIL PROTECTED]>
> Subject: Re: When is send-hook applied?
> 
> On Tue, May 14, 2002 at 04:29:30PM -0400, Sweth Chandramouli wrote:
> >     This leads me to believe that send-hook is applied before
> > the full message is built, and more specifically before the headers
> > against which I'm matching are available (or maybe only certain headers
> > are passed in to the hook).  Is that the case?  The docs vaguely imply
> > that it is, by saying that send-hook is used to match recipients, but
> > they also say that the description of patterns in "Message Matching in
> > Hooks" applies, and that description explicitly references other headers
> > like "From:".
> Your assessment here is correct.  You can really only match against the
> to: and cc: fields of the new message.  The rest of the header fields
> are generated after the send-hook's are evaluated, since typically the
> user wants to alter settings based upon the address(es) they are sending
> to (most notably the From: line).
        I assume you mean "To:" rather than "From:"; if that's the
case, is there any way to accomplish what I want?  The only other
solution I can think of is to map my "reply" button to pipe the current
mail into a script that generates a template based on whatever logic I'd
like to use (although I still haven't figured out how to pass info to
that script about what folder I'm in, etc.), and then reinvokes mutt with
the -H flag specifying that template for the header info.  That just
seems too kludgy for words, however.

        Thanks,

        Sweth.

-- 
Sweth Chandramouli      Idiopathic Systems Consulting
[EMAIL PROTECTED]      http://www.idiopathic.net/

Reply via email to