unix command file HELP

Frederick M. Avolio avolio at decuac.UUCP
Thu Feb 6 23:28:42 AEST 1986


In <245 at aero.ARPA> sutton at aero.UUCP (Stew Sutton) writes:
> We are looking for a utility that can, when given a arbitrary string,
> can locate all occurences of that string anywhere on the system. ...

In article <139 at wgivax.UUCP>, mo at wgivax.UUCP flames about untested
"solutions" posted to the net in answer to questions.

There have been many solutions (real or otherwise) posted to this
question.  All I'd like to add is the suggestion DON'T DO IT.  Before
you search for an occurence of a string in a set of files, always hone
down that set of files to a reasonable subset.  If it is something
coming from a library, look ONLY in directories containing libraries
or their sources.  If it is something coming from an executable,
search only in directories that contain executables.  If you know it
is in the operating system, only search directories containing
operating system sources.  There is a big difference in the number of
files searched between "find / ...." and "find /usr/src/sys ...".

A little smarts go a long way...
-- 
Fred @ DEC Ultrix Applications Center    {decvax,seismo,cbosgd}!decuac!avolio



More information about the Comp.unix mailing list