Re: searching a directory sub-tree.

2025-03-29 Thread home user via users
On 3/27/25 10:29 PM, Jon LaBadie wrote: On Wed, Mar 26, 2025 at 03:00:21PM -0600, home user via users wrote: Good afternoon, I'm trying to search a directory sub-tree for a specific string.  I use this: find . -type f -print | xargs grep -l [string] /dev/null (but without the brackets).  This

Re: searching a directory sub-tree.

2025-03-27 Thread Jon LaBadie
On Wed, Mar 26, 2025 at 03:00:21PM -0600, home user via users wrote: Good afternoon, I'm trying to search a directory sub-tree for a specific string. I use this: find . -type f -print | xargs grep -l [string] /dev/null (but without the brackets). This often works. But it sometimes fails whe

Re: searching a directory sub-tree.

2025-03-27 Thread Patrick O'Callaghan
On Wed, 2025-03-26 at 17:39 -0600, home user via users wrote: > On 3/26/25 4:14 PM, Patrick O'Callaghan wrote: > > On Wed, 2025-03-26 at 15:47 -0600, home user via users wrote: > > > A co-worker back in the late 1980's gave that "find" line.  I'm curious: > > > did "grep" have the -r option back t

Re: searching a directory sub-tree.

2025-03-26 Thread home user via users
On 3/26/25 4:14 PM, Patrick O'Callaghan wrote: On Wed, 2025-03-26 at 15:47 -0600, home user via users wrote: A co-worker back in the late 1980's gave that "find" line.  I'm curious: did "grep" have the -r option back then? Maybe my memory is faulty but I don't remember grep ever not having th

Re: searching a directory sub-tree.

2025-03-26 Thread Samuel Sieb
On 3/26/25 2:49 PM, Go Canes wrote: On Wed, Mar 26, 2025 at 5:19 PM Jerry James wrote: On Wed, Mar 26, 2025 at 3:01 PM home user via users wrote: I'm trying to search a directory sub-tree for a specific string. I use this: find . -type f -print | xargs grep -l [string] /dev/null [...] Ho

Re: searching a directory sub-tree.

2025-03-26 Thread Patrick O'Callaghan
On Wed, 2025-03-26 at 15:47 -0600, home user via users wrote: > A co-worker back in the late 1980's gave that "find" line.  I'm curious: did > "grep" have the -r option back then? Maybe my memory is faulty but I don't remember grep ever not having the '-r' option and I've been using it since the

Re: searching a directory sub-tree.

2025-03-26 Thread Go Canes
On Wed, Mar 26, 2025 at 5:48 PM home user via users wrote: > The sub-tree I'm searching is loaded with huge binary files along with some > ".txt" files. The searches take several minutes each. How do I restrict the > search to ".txt" files? ... Same as my previous reply, adding .txt to the w

SOLVED - Re: searching a directory sub-tree.

2025-03-26 Thread home user via users
On 3/26/25 3:52 PM, Samuel Sieb wrote: On 3/26/25 2:49 PM, Go Canes wrote: On Wed, Mar 26, 2025 at 5:19 PM Jerry James wrote: On Wed, Mar 26, 2025 at 3:01 PM home user via users wrote: I'm trying to search a directory sub-tree for a specific string.  I use this: find . -type f -print | xar

Re: searching a directory sub-tree.

2025-03-26 Thread Go Canes
On Wed, Mar 26, 2025 at 5:52 PM Samuel Sieb wrote: > > On 3/26/25 2:49 PM, Go Canes wrote: > > On Wed, Mar 26, 2025 at 5:19 PM Jerry James wrote: > >> > >> On Wed, Mar 26, 2025 at 3:01 PM home user via users > >> wrote: > >>> I'm trying to search a directory sub-tree for a specific string. I us

Re: searching a directory sub-tree.

2025-03-26 Thread home user via users
On 3/26/25 3:17 PM, Jerry James wrote: On Wed, Mar 26, 2025 at 3:01 PM home user via users wrote: Good afternoon, I'm trying to search a directory sub-tree for a specific string. I use this: find . -type f -print | xargs grep -l [string] /dev/null (but without the brackets). This often wor

Re: searching a directory sub-tree.

2025-03-26 Thread Samuel Sieb
On 3/26/25 2:47 PM, home user via users wrote: Part 2 The sub-tree I'm searching is loaded with huge binary files along with some ".txt" files.  The searches take several minutes each.  How do I restrict the search to ".txt" files? ... -I -- ___ us

Re: searching a directory sub-tree.

2025-03-26 Thread Go Canes
On Wed, Mar 26, 2025 at 5:19 PM Jerry James wrote: > > On Wed, Mar 26, 2025 at 3:01 PM home user via users > wrote: > > I'm trying to search a directory sub-tree for a specific string. I use > > this: > > > > find . -type f -print | xargs grep -l [string] /dev/null [...] > > How do I get this t

Re: searching a directory sub-tree.

2025-03-26 Thread Jerry James
On Wed, Mar 26, 2025 at 3:01 PM home user via users wrote: > Good afternoon, > > I'm trying to search a directory sub-tree for a specific string. I use this: > > find . -type f -print | xargs grep -l [string] /dev/null > > (but without the brackets). This often works. But it sometimes fails whe