Gnus development mailing list
 help / color / mirror / Atom feed
From: Paul Stevenson <spaul@mail.phy.ornl.gov>
Subject: Re: Name washing
Date: 14 Dec 1999 16:48:47 -0500	[thread overview]
Message-ID: <m2ln6xi474.Indonesian@bethe.phy.ornl.gov> (raw)
In-Reply-To: Paul Stevenson's message of "14 Dec 1999 15:51:31 -0500"

Paul Stevenson <spaul@mail.phy.ornl.gov> writes:

> Has anyone written, or does gnus already have some function to wash
> names?
>
> [snip]

okay, it was easier than I thought for just a very simple heuristic
algorithm:


(defun ps-wash-name (name)
  (if (stringp name)
      (if (string= name (car (split-string name "(")))
	  (progn
	    (if (string= name (car (split-string name "<")))
		(car (split-string name "@"))
	      (car (split-string name " <"))))
	(car (cdr (split-string name "(\\|)"))))
    "Fudged name"))

then with 

(defun gnus-user-format-function-a (headers)
  (let ((name (aref headers 2)))
    (ps-wash-name name)))

I can have 

(setq gnus-summary-line-format "%U%R%z%I%(%[%4L: %-20,20ua%]%) %s\n")

and it does most of what I want. woo-hoo. Hooray for
gnus-user-format-function


  reply	other threads:[~1999-12-14 21:48 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-14 20:51 Paul Stevenson
1999-12-14 21:48 ` Paul Stevenson [this message]
1999-12-14 22:04   ` Paul Stevenson
     [not found]   ` <wtniu20lgtz.fsf@licia.dtek.chalmers.se>
1999-12-17 13:47     ` Paul Stevenson
1999-12-21 20:52       ` Kai Großjohann
1999-12-15 11:04 ` Toby Speight

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2ln6xi474.Indonesian@bethe.phy.ornl.gov \
    --to=spaul@mail.phy.ornl.gov \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).