This isn't strictly a Perl question. In shell:
$ grep -v x filename | grep -v y | grep -v z
With perl:
$ perl -ne 'print unless /x|y|z/' filename
It sound's like you have some problem with the shell solution, but I
don't know what it might be.
Jon
>I am trying to parse lines out of a txt file. Instead of running the
>command three times, how can I add all the parameters together for the
>-v option. Thanks for the help.
Are you asking about grep or perl? Hint: '|' *may* be what you want in
both cases...
Michele
--
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
.'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,
> Subject: Grep -v option
grep(1) is not Perl.
Did you have a Perl question?
--
Tad McClellan SGML consulting
ta...@augustmail.com Perl programming
Fort Worth, Texas
Which -v option are you talking about? "perldoc -f grep" doesn't mention it.
jue
egrep allows alternation, no?