Web lists-archives.com

Re: An appropriate directory search tool?




On Mon, Oct 22, 2018 at 10:24:35AM -0500, David Wright wrote:
> > > On Sun 21 Oct 2018 at 05:25:05 (-0500), Richard Owlett wrote:
> > > > I wish a list of files with a specific extension in a directory which
> > > > contain keywordA but not keywordB. Recursing down the directory tree
> > > > was the primary objection to the MATE search tool.
>                       ↑↑↑↑↑↑↑↑↑

> Specifically required by the OP.

I found the wording ambiguous, but I'm also only seeing the text
second-hand, without the full context.  So, I'll take part of the blame
for this, but not all of it.

*Most* people who are searching for the files containing a specific
pattern starting in a specific directory *want* recursion.  So, asking
that the search NOT recurse needs to be spelled out in extremely
explicit language.

With any of the find solutions that have already been given, one may
add "-maxdepth 1" to stop the recursion.  That's a non-portable option,
but this is debian-user, so it's perfectly acceptable here.