Need unix command file HELP!

hamilton at uiucuxc.CSO.UIUC.EDU hamilton at uiucuxc.CSO.UIUC.EDU
Tue Feb 4 15:48:00 AEST 1986


our mailer couldn't find "sutton at aero".

>We are looking for a utility that can, when given a arbitrary string,
>can locate all occurences of that string anywhere on the system. Our
>local Un*x gurus can't figure this out, so we are appealing to those out
>in Netland to help us out.

try something like:

    find / -type f -a -exec fgrep -s this-is-the-string \{\} \; -a -print 

if possible, add extra terms to limit the search.  for example, if you
want to search only for C source files, add:
	-name \*.c -a
before the "-exec".

you could certainly write something more efficient, but do you really
need it that often?

	wayne hamilton
	U of Il and US Army Corps of Engineers CERL
UUCP:	{ihnp4,pur-ee,convex}!uiucdcs!uiucuxc!hamilton
ARPA:	hamilton%uiucuxc at a.cs.uiuc.edu	USMail:	Box 476, Urbana, IL 61801
CSNET:	hamilton%uiucuxc at uiuc.csnet	Phone:	(217)333-8703



More information about the Comp.unix.wizards mailing list