Gnus development mailing list
 help / color / mirror / Atom feed
* carry over headers into reply
@ 2012-06-02 12:02 Eric Abrahamsen
  2012-06-03  9:05 ` Eric Abrahamsen
  0 siblings, 1 reply; 2+ messages in thread
From: Eric Abrahamsen @ 2012-06-02 12:02 UTC (permalink / raw)
  To: ding

I've been trying for a while to figure out how to draw the value of a
custom header from an edited mail message (the header inserted via
another function) and insert it into a reply to that message. I can't
seem to find any hooks (or even efficient places to advise functions)
that will let me slurp a header value from the original message, and
then place it in the reply that's being composed.

I've considered `message-fetch-reply-field' (which seemed promising),
and a custom `message-reply-to-function', and also advising
`message-get-reply-headers', but everything seems to only let me carry
over To and Cc headers from the original, not arbitrary headers.

I can always kludge it with some global variable and two advice forms,
but I'd much rather find something more graceful.

Is there anywhere where either advice or a hook can use
`message-fetch-reply-field' to get fields from the original, while
operating in the reply buffer?

If anyone who knows this code has a word of advice, I would love to hear
it!

Thanks,
Eric

-- 
GNU Emacs 24.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.24.10)
 of 2012-06-01 on pellet
Ma Gnus v0.6




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: carry over headers into reply
  2012-06-02 12:02 carry over headers into reply Eric Abrahamsen
@ 2012-06-03  9:05 ` Eric Abrahamsen
  0 siblings, 0 replies; 2+ messages in thread
From: Eric Abrahamsen @ 2012-06-03  9:05 UTC (permalink / raw)
  To: ding

On Sat, Jun 02 2012, Eric Abrahamsen wrote:

> I've been trying for a while to figure out how to draw the value of a
> custom header from an edited mail message (the header inserted via
> another function) and insert it into a reply to that message. I can't
> seem to find any hooks (or even efficient places to advise functions)
> that will let me slurp a header value from the original message, and
> then place it in the reply that's being composed.

Answering my own question, `message-fetch-reply-field' does exactly
this.


-- 
GNU Emacs 24.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.24.10)
 of 2012-06-01 on pellet
Ma Gnus v0.6




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-06-03  9:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-06-02 12:02 carry over headers into reply Eric Abrahamsen
2012-06-03  9:05 ` Eric Abrahamsen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).