procmail
[Top] [All Lists]

Re: newline

2002-06-05 03:06:13
On Wed, 5 Jun 2002 erik(_at_)dd(_dot_)nec(_dot_)com(_dot_)au wrote:

On Tue, Jun 04, 2002 at 09:06:32PM +0300, Udi Mottelo wrote:

    But ofcource!   Also:

awk -F"^M" '{print $1}'


Udi,

   This doesn't work for me, possibly because -F specifies the
Field Separator, not the Record Separator.

        I wander, I checked it on Solaris7 (awk, nawk) and RedHat7.2
        please, try in you system:

yarkon~% echo -n "hello:" | awk -F":" '{print $1; print NF}'
hello
2
yarkon~%

        Is ":" a Field Separator or Record Separator? (notice the "-n")
        Maybe the gnu has different answer.

        However, for procmail usage I belive that tr(1) or cut(1) are
        much more efficient and elegant.

Bye,
 Udi

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>