Gnus development mailing list
 help / color / mirror / Atom feed
* Re: function to get "To" address from the header
       [not found]   ` <u7kvm7yqw.fsf@cisco.com>
@ 2001-08-30 10:57     ` Dirk Meyer
  2001-08-30 12:02       ` Kai Großjohann
  0 siblings, 1 reply; 3+ messages in thread
From: Dirk Meyer @ 2001-08-30 10:57 UTC (permalink / raw)


Pranav K. Tiwari wrote:
> Kai.Grossjohann@CS.Uni-Dortmund.DE (Kai Großjohann) writes:
>
>> anti-spam-pranav@cisco.com (Pranav K. Tiwari) writes:
>> 
>> > [Remove 'anti-spam-' from the front of my address to reply]
>> >
>> > Is there a function to get the "To" address out of a mail header? I want to
>> > use it in gnus-summary-line-format to display the recipient's name in
>> > summary line (only in nndraft folders).
>> 
>> See the node "To From Newsgroups" in the Gnus info file.
>> 
>
> Thanks for the pointer, Kai. But I couldn't get it to work the way I wanted
> to:
>
> Here's what I set after reading the info page:
>
> (setq gnus-extra-headers '(To Newsgroups)
>       nnmail-extra-headers gnus-extra-headers
>       gnus-ignored-from-addresses "Pranav"
>       gnus-summary-line-format "%z%U%R%I%[%4L: %-15,15a -> %-15,15~(form (gnus-extra-header 'To))@]%2t %s : on %D\n")
>

This doesn't work for me. %L und %D are empty in nndraft:draft because
the Date-Header is still missing. 

Is it possible to add the missing headers when saving the message with
C-x C-s?


Dirk

-- 
Real Men don't make backups.  They upload it via ftp and let the world
mirror it.
	-- Linus Torvalds


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

* Re: function to get "To" address from the header
  2001-08-30 10:57     ` function to get "To" address from the header Dirk Meyer
@ 2001-08-30 12:02       ` Kai Großjohann
  2001-08-30 14:57         ` Dirk Meyer
  0 siblings, 1 reply; 3+ messages in thread
From: Kai Großjohann @ 2001-08-30 12:02 UTC (permalink / raw)
  Cc: ding

Dirk Meyer <dischi@tzi.de> writes:

> This doesn't work for me. %L und %D are empty in nndraft:draft because
> the Date-Header is still missing. 
>
> Is it possible to add the missing headers when saving the message with
> C-x C-s?

Maybe (setq message-generate-headers-first t) and
(add-to-list 'message-deletable-headers 'Date)?

kai
-- 
Symbol's function definition is void: signature


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

* Re: function to get "To" address from the header
  2001-08-30 12:02       ` Kai Großjohann
@ 2001-08-30 14:57         ` Dirk Meyer
  0 siblings, 0 replies; 3+ messages in thread
From: Dirk Meyer @ 2001-08-30 14:57 UTC (permalink / raw)


Kai Großjohann wrote:
> Dirk Meyer <dischi@tzi.de> writes:
>
>> This doesn't work for me. %L und %D are empty in nndraft:draft because
>> the Date-Header is still missing. 
>>
>> Is it possible to add the missing headers when saving the message with
>> C-x C-s?
>
> Maybe (setq message-generate-headers-first t) and
> (add-to-list 'message-deletable-headers 'Date)?

Thanks. I don't like all headers as default, but with your tip I wrote   

(defun message-generate-headers-and-save ()
  (interactive)
  (message-generate-headers
   (if (message-news-p)
       message-required-news-headers
     message-required-mail-headers))
  (save-buffer))


(define-key message-mode-map "\C-x\C-s" 'message-generate-headers-and-save)


to add the headers only when saving the message. Now it works perfect
in nndraft:draft.

Dirk

-- 
Don't read everything you believe.


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

end of thread, other threads:[~2001-08-30 14:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <u3d6bgo1g.fsf@cisco.com>
     [not found] ` <vafn14ik8j2.fsf@lucy.cs.uni-dortmund.de>
     [not found]   ` <u7kvm7yqw.fsf@cisco.com>
2001-08-30 10:57     ` function to get "To" address from the header Dirk Meyer
2001-08-30 12:02       ` Kai Großjohann
2001-08-30 14:57         ` Dirk Meyer

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).