Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!samsung!noose.ecn.purdue.edu!gus17.ecn.purdue.edu!luj From: luj@gus17.ecn.purdue.edu (Jun Lu) Newsgroups: comp.unix.questions Subject: Re: how to grep multiply strings Keywords: grep regular expression Message-ID: <1991Feb27.195124.24552@noose.ecn.purdue.edu> Date: 27 Feb 91 19:51:24 GMT References: <531@ctycal.UUCP> Sender: root@noose.ecn.purdue.edu (ECN System Management) Organization: Purdue University School of Aeronautics and Astronautics Lines: 21 In article <531@ctycal.UUCP> pat@ctycal.UUCP (Patrick Woo) writes: >I am trying to display line that doesn't contain string1 or string2 or ... >stringn. > >What I did was > >grep -v string1 | grep -v string2 | .... | grep -v stringn > >Just wondering if there is an easier way other than doing all this piping. >Thanks in advance. > How about egrep -v 'string1|string1|...|stringn' ? -- -- Jun Lu Internet:luj@ecn.purdue.edu -- -- Aeronautics & Astronautics Bitnet: luj%ecn.purdue.edu@purccvm -- -- Purdue University UUCP: pur-ee!luj -- -- W. Lafayette, IN 47907 Phone:317-494-9410 Fax:317-494-0307 --