On 20:26 06 Mar 2002, Vidiot <[EMAIL PROTECTED]> wrote:
| >Hey everyone, I am trying to make a "FROM" script that basically shows =
| >the person running the script who the mail is from that they have.
|
| How about:
|
| sed -e '/^From /b' -e d
|
| The only legal from at the beginning is "From "
Too verbose:
sed 1q
works fine since "From " is the first line.
However, that's the envelope. May well _not_ be the author after passing through a
mailing
list or gateway. If you want the "From:" line:
sed -n '/^[Ff][Rr][Oo][Mm]:/p'
will do the trick.
--
Cameron Simpson, DoD#743 [EMAIL PROTECTED] http://www.zip.com.au/~cs/
In life, you should always try to know your strong points, but this is
far less important than knowing your weak points.
Martin Fitzpatrick <[EMAIL PROTECTED]>
_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list