----- Original Message ----- 
From: Ashok Vadekar <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 11, 2001 4:54 PM
Subject: Re: Recursive grep [WAS: Re: date]


> On Thu, Jan 11, 2001 at 04:36:14PM -0500, Earnie Boyd wrote:
> > find . -name \*.cc -exec echo '{}' ';' -exec grep getenv '{}' ';'
> Or with fewer keystrokes:
> find . -name \*.cc -print -exec grep getenv '{}' ';'
> 
> --

If you put the "-print" at the end, it will then only
print the file name of files in which grep finds a match

For example, from bash, try

   find . -name '*.c' -exec grep getenv {} \; -print

Just my $0.02

--Mark



--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

Reply via email to