Re: ls -R | grep char_string

2000-10-30 Thread kmself
on Sun, Oct 29, 2000 at 11:39:04PM +, sena ([EMAIL PROTECTED]) wrote: I heard that Christoph H. wrote this on 29/10/00: You are searching for a string in the name of all files in the current dir and subdirs, but I think you want to search for a string _within_ all files.

Re: ls -R | grep char_string

2000-10-30 Thread kmself
on Sun, Oct 29, 2000 at 12:36:17PM -0800, Erik Steffl ([EMAIL PROTECTED]) wrote: or slightly more effective: find . -type f |xargs grep char_string /dev/null I prefer: $ find . -type f -print0 | xargs --null zgrep -l pattern ...though as noted, the grep -r construct is simpler when

Re: ls -R | grep char_string

2000-10-30 Thread kmself
Any reason this is off list? List cc:'ed in response. on Mon, Oct 30, 2000 at 04:24:36AM -0900, Ethan Benson ([EMAIL PROTECTED]) wrote: On Mon, Oct 30, 2000 at 03:16:32AM -0800, kmself@ix.netcom.com wrote: I prefer: $ find . -type f -print0 | xargs --null zgrep -l pattern

ls -R | grep char_string

2000-10-29 Thread robert_wilhelm_land
I would like to search all files in the current und subdirs for a char_string. Why does this commandstring not work?: ls -R | grep char_string No error , no nothing - although this certain char_string is in a simple ASCII text file! Robert

Re: ls -R | grep char_string

2000-10-29 Thread Christoph H.
I would like to search all files in the current und subdirs for a char_string. Why does this commandstring not work?: ls -R | grep char_string No error , no nothing - although this certain char_string is in a simple ASCII text file! You are searching for a string in the name of all files

Re: ls -R | grep char_string

2000-10-29 Thread Erik Steffl
Christoph H. wrote: I would like to search all files in the current und subdirs for a char_string. Why does this commandstring not work?: ls -R | grep char_string No error , no nothing - although this certain char_string is in a simple ASCII text file! You are searching

Re: ls -R | grep char_string

2000-10-29 Thread Krzys Majewski
Erik Steffl [EMAIL PROTECTED] writes: find . -type f |xargs grep char_string /dev/null I use find . -type f | xargs mogrep $1 where $1 is the expression to search for, and mogrep (below) knows what to do with binary and compressed files. -chris #!/bin/sh REGEXP=$1 PRGNAME=`basename

Re: ls -R | grep char_string

2000-10-29 Thread sena
I heard that Christoph H. wrote this on 29/10/00: You are searching for a string in the name of all files in the current dir and subdirs, but I think you want to search for a string _within_ all files. Therefore you have to do something like that: find . -exec grep -H char_string {} \;

RE: ls -R | grep char_string

2000-10-29 Thread Kenrick, Chris
Krzys writes: and mogrep (below) knows what to do with binary and compressed files. -chris Unfortunately mogrep as implemented relies on the file names to determine the file type. A neater way might be to use the 'file' command to determine the file type eg: [EMAIL PROTECTED]:~$ file * dl:

Re: ls -R | grep char_string

2000-10-29 Thread Christoph H.
Am Montag, 30. Oktober 2000 00:39 schrieb sena: I heard that Christoph H. wrote this on 29/10/00: You are searching for a string in the name of all files in the current dir and subdirs, but I think you want to search for a string _within_ all files. Therefore you have to do something