Networking Forums

Networking Forums > Computer Networking > Linux Networking > How to search through all the files in all the levels of your directories.

Reply
Thread Tools Display Modes

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

 
 
dsaklad@zurich.csail.mit.edu
Guest
Posts: n/a

 
      03-05-2005, 03:16 AM
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 thought all files in all the levels of my
directories

 
Reply With Quote
 
 
 
 
Carl Fink
Guest
Posts: n/a

 
      03-05-2005, 03:49 AM
On 2005-03-05, (E-Mail Removed) <(E-Mail Removed)> wrote:
> In emacs, what can be done to run a command?... like
> find -type f -print0 |xargs -0 grep -i foo


Why are you bringing up emacs?

Did you try "find / -type f -exec grep -i foo {} \;"?



Come to think of it, what does this have to do with networking? For
that matter, what does it have to do with Linux? "find" is not a
Linux-specific program.
--
Carl Fink (E-Mail Removed)
Ask me about I-Con 24, April 8-10, 2005
http://iconsf.org
 
Reply With Quote
 
Mark
Guest
Posts: n/a

 
      03-11-2005, 04:48 AM
On Fri, 04 Mar 2005 20:16:37 -0800, dsaklad wrote:

> In emacs, what can be done to run a command?... like
> find -type f -print0 |xargs -0 grep -i foo


Don't know much about emacs

> I'm trying to search thought all files in all the levels of my
> directories


Not sure where emacs figures into all this, but you can always use:
egrep -ri "is this a network question" .

This will search all files, in all directories, below your current root.
Note, the 'i' means case insensitive.

Mark
 
Reply With Quote
 
GreyBeard
Guest
Posts: n/a

 
      03-11-2005, 05:57 AM
On Fri, 04 Mar 2005 20:16:37 -0800, dsaklad 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 thought all files in all the levels of my
> directories


If you run "man grep" on your system, you will be able to check whether
grep on your system supports the Recursive option.

IOW: you might be able to run,

grep -Ri foo *

as I've done on all my SuSE and RH systems for several years now. The -R
means recurse through directories.

However, I've always run this in a shell, never in emacs.

/FGB
 
Reply With Quote
 
Coenraad Loubser
Guest
Posts: n/a

 
      03-11-2005, 12:34 PM
Whats wrong with

"updatedb"

and

"locate"

???

And see where your space is being chowed.. , "du"






 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
New Search Engine Launched - Ogleo.com - An Integrated Search Engine Shaine Wireless Internet 1 01-27-2007 03:42 PM
Unable to download deep files and directories recursively with mget -R command... ANTant@zimage.com Linux Networking 9 02-21-2005 07:35 AM
Two levels of ICS possible? Tom Walker Windows Networking 1 01-09-2004 07:10 PM
New files/directories having a specific group Alex Linux Networking 5 09-21-2003 07:50 AM
Search files on LAN John Smith Home Networking 1 09-05-2003 03:03 AM



1 2 3 4 5 6 7 8 9 10 11