Re: An appropriate directory search tool?
- Date: Sun, 21 Oct 2018 09:52:51 +0000 (UTC)
- From: Curt <curty@xxxxxxx>
- Subject: Re: An appropriate directory search tool?
On 2018-10-20, Richard Owlett <rowlett@xxxxxxxxxxx> wrote:
> But they did.
> That's why I wrote 'My take away from answers so far is "A script will
> be required." '
> Perhaps we have different ideas of the definition of "script".
> I saw the examples which worked as scripts (even if written as one
> liners). If I had attempted to use bash, I would have expected to use an
> explicit pipe command between 'find' and 'grep'.
If you want to search a specific directory for files that do not contain
a certain string (a desire I believe you expressed somewhere along the
way), grep alone appears to meet that bill:
grep -rL ~/my_directory -e "my string"
Of course, this is now a case of the blind guy appointing himself king of the
realm of the one-eyed man (you in this strained analogy).
"Now she understood that Anna could not have been in lilac, and that her charm
was just that she always stood out against her attire, that her dress could
never be noticeable on her." Leo Tolstoy, Anna Karenina