Re: How to search through all the files in all the levels of your directories.

From: Lars Øhlenschlæger (lars_oeh_at_tiscali.dk)
Date: 03/05/05


Date: Sat, 05 Mar 2005 17:17:16 +0100

dsaklad@zurich.csail.mit.edu wrote:
> In emacs, what can be done to run a command?... like
> find -type f -print0 |xargs -0 grep -i foo
>
> The prompt appeared and an error message...
> Fatal error (11).Segmentation fault
>
> I'm trying to search though all files in all the levels of my
> directories
>
Try:
find / -type f -exec grep -i foo "" {} \; 2> /dev/null

This will list full path to all files including "foo" (case insensitive)
  + the line containing "foo"

Note: You MUST have read access to the files you scan.

/Lars



Relevant Pages