Pipes WAS Re: [Sussex] linux command line

Mark Harrison Mark at ascentium.co.uk
Thu Jan 13 18:42:29 UTC 2005


----- Original Message ----- 
From: "Thomas Adam" <thomas at edulinux.homeunix.org>
To: <sussex at mailman.lug.org.uk>
Sent: Thursday, January 13, 2005 5:52 PM
Subject: Re: Pipes WAS Re: [Sussex] linux command line


> On Thu, Jan 13, 2005 at 05:48:32PM -0000, Mark Harrison wrote:
> > cat log.txt | grep "error" | sort -u
>
> > Mark Proudly using pipes since 1989 :-)
>
> Except you win the UUoCA (Useless Use of Cat Award) for that command.
>
> grep error ./log.txt | sort -u
>
> ... is much better.
>
> -- Thomas Adam

Sorry - I was trying to come up with a command that showed multiple pipes
being used to form a command, without making it so confusing that people
were head-scratching to see what it did.

Oh, and I used to use SunOS before it became that new-fangled Solaris thing,
so I'm used to writing cat...  | grep :-)

M





More information about the Sussex mailing list