[97598] in RedHat Linux List
grep syntax
daemon@ATHENA.MIT.EDU (Robert W. Canary)
Tue Nov 3 23:48:53 1998
Date: Tue, 03 Nov 1998 22:49:15 -0600
From: "Robert W. Canary" <rwcanary@ohiocounty.net>
Reply-To: rwcanary@mail.lig.bellsouth.net
To: redhat-list@redhat.com
Resent-From: redhat-list@redhat.com
Hi,
I am trying find the correct syntax for grep a directory and excluding
certain files from the output.
EXCEPTIONS="ttyC4 ttyC5"
command ls /var/lock | grep tty[SC] | {filter out $EXCEPTIONS}
I can filter out the exception with "grep -v ttyC4 | grep -v ttyC0", but
I need to be able to feed it a variable that contians a list of some
sort.
thanks in advance :-)
--
robert
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com http://archive.redhat.com
To unsubscribe: mail redhat-list-request@redhat.com with
"unsubscribe" as the Subject.