Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: Notesfiles $Revision: 1.7.0.10 $; site ccvaxa Path: utzoo!watmath!clyde!cbosgd!ihnp4!inuxc!pur-ee!uiucdcs!ccvaxa!aglew From: aglew@ccvaxa.UUCP Newsgroups: net.unix Subject: Re: Need unix command file HELP! Message-ID: <1900018@ccvaxa> Date: Mon, 3-Feb-86 23:18:00 EST Article-I.D.: ccvaxa.1900018 Posted: Mon Feb 3 23:18:00 1986 Date-Received: Thu, 6-Feb-86 04:38:32 EST References: <245@aero.ARPA> Lines: 19 Nf-ID: #R:aero.ARPA:245:ccvaxa:1900018:000:666 Nf-From: ccvaxa.UUCP!aglew Feb 3 22:18:00 1986 I came up with this csh alias for a recursive grep at the beginning of this year when I had to do a lot of code reading: alias rgl find !:2* -name \* -exec grep -l !:1 /dev/null \{\} \; It works, but is blessed slow. Our version of find, at least, will mess up if you have cycles in your directory tree; it will also find link-aliased files many times. The /dev/null is to force our version of grep to print out the filename when there is only one file (wildcards can be worked in to make it more efficient, but it gets messy enough to need a shell script (if not, tell me!)).