Hi Chris
On Thursday 22 February 2007 10:50, Eur Ing Chris Green wrote:
While the 'locate' command is very useful at times, especially if you have lost a specific file it's much less useful when looking for, for example, a directory which has a rather common name.
My first reaction was use `find`, but....
I know I can use an RE in locate but it's not all *that* simple to come up with an RE to do it.
A quick look at `man locate` shows that it provides many of the same options as find. If it is a directory you seek, use `-type d`, and to limit the depth of search, add `-maxdepth 3` - None of which involve gnarly regexs ;)
Regards, Paul.