[Ilugc] recursive search

  • From: sureshkumar.s@xxxxxxxxxx (Suresh Kumar Subramanian)
  • Date: Wed Jan 13 13:50:01 2010

Hi,

How to find the text from a file(directory & subdirectory). (recursive search)

Ex :
Directories :
/prog
/prog/sub1/
/prog/sub1/dir1/
/prog/sub2/

Each folder contains some text files.

I want to search a "text" from all the files in the directory /prog and 
subdirectories.

I tried
cat * | grep "text"  But it searches only the current directory also it not 
lists the filename.

How do I do this

Thanks
Suresh

Other related posts: