Subject: Re: How to do ...

From: [email-masked] (David W. Tamkin)
Date: Tue, 13 Sep 1994 18:44:39 -0500 (CDT)

Anand Gupta wrote,

| I need a recipe which will extract the  the sender and save the message in
| the folder bearing his/her name.

Two questions:

1. Who is the "sender"?  Is it the name (whatever that is: see question 2) in
   the From: header or the name in the From_ header?  If there is a Reply-To:
   header, does the name in Reply-To: override From: and From_?  What if
   there is a Sender: header?

2. What is a "name"?  Is it the first name, the last name, the complete name
   with the embedded space included, or perhaps the system username?

Whatever the answers to these questions, the resulting operation is possible.
We just don't know precisely what you want.

It might be as simple as this:

  :0
  * conditions
  {
   # get return address and strip site and domain information off
   SAVENAME=`formail -rtx To: | sed -e 's/@.*//' -e 's/.*\!//'`

   :0:
   $SAVENAME
  }

David W. Tamkin  P. O. Box 3284  Skokie IL  60076-6284
[email-masked]   MCI Mail: 426-1818   +1 312 714 5610