for a file:
find / -type f -name "<regular expression>" -print
for a directory:
find / -type d -name "<regular expression>" -print
for anything other than a filename:
find / ! -type f -name "<regular expression>" -print
Also
man find
man regexp
both worth reading and getting to grips with.
> ...for both? If you do this searching alot, try 'locate' (you may have
> to run 'updatedb' beforehand, but it makes a db and saves your drives from
> the gronking effects of running 'find's all the time.
>
> neil doane
>
> >
> >
> >
> > A2. grep for a dir:
> >
> > Thanks,
> > Daniel Avila
> >
> >
-- Regards Richard ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ wsvir.jemsrmupxc@bbklaw.com Phone +44 1666 833183 Fax +44 1666 832844 Lucent Technologies, Swindon Road, Malmesbury, Wiltshire, UK. SN16 9NA Amateur radio callsign: G1SOG Home BBS: G1SOG@GB7SDN.#49.GBR.EU My opinions are mine, all mine. None to spare for unopinionated masses. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~