Date: Thu, 7 Mar 2002 16:20:58 +0100 From: Benoit Lacherez <blacherez@ac-bordeaux.fr> To: mpd <mpd6334@cs.rit.edu> Cc: questions@freebsd.org Subject: Re: grep.... recursive searching Message-ID: <20020307162058.A27299@bisclavret.iris33.ac-bordeaux.f> In-Reply-To: <20020307091002.A45751@rochester.rr.com>; from mpd6334@cs.rit.edu on Thu, Mar 07, 2002 at 09:10:03AM -0500 References: <20020307101335.6460.qmail@web20102.mail.yahoo.com> <20020307091002.A45751@rochester.rr.com>
next in thread | previous in thread | raw e-mail | index | archive | help
mpd a écrit : > On Thu, Mar 07, 2002 at 02:13:35AM -0800, Bsd Neophyte wrote: > > > > I'm reading up on grep... (thanks for the explaining the find command... > > that let me move forward)... and i've noticed that while you can search > > for a "regular expression" (did I use that right?) there is no mention of > > any ability to do a recursive search. > > > > i checked the man page and seached for the "regular expression" (this will > > be on a quiz tomorrow... that's why i'm using it so much :D ) "recursive" > > but nothing came up. > > > > is there some uncomplicated way of doing a recursive search with grep? > > > > -Sameer > > > > I'm more curious of a way to make it recurse through all the > directories, but only try to match on certain files. > Is this even possible with this version of grep? The fm (of > rtfm fame) isn't giving me any epiphanies. > What about find ? find . -name \*.c (or whatever condition(s) you like) -exec egrep -H 'pattern' {} \; -- Benoit Lacherez Académie de Bordeaux -- CATICE Projet de traduction de la documentation de Python: http://frpython.sourceforge.net/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020307162058.A27299>