Re: RFC: -exit option for find(1)

2004-07-26 Thread Ruslan Ermilov
On Fri, Jul 16, 2004 at 12:23:41AM -0700, Alfred Perlstein wrote: I'm up too late, this doesn't work because find returns success whenever it successfully runs thought everything. Perhaps the primary change to just -exit which would make find exit successfully, and if the primary is never

Re: RFC: -exit option for find(1)

2004-07-17 Thread Oliver Eikemeier
Peter Pentchev wrote: On Fri, Jul 16, 2004 at 05:28:57PM +0300, Peter Pentchev wrote: On Fri, Jul 16, 2004 at 11:58:07AM +0400, Denis Antrushin wrote: Alfred Perlstein wrote: I'm up too late, this doesn't work because find returns success whenever it successfully runs thought everything. Perhaps

RFC: -exit option for find(1)

2004-07-16 Thread Alfred Perlstein
This adds a primary to find(1) -exit arg, it will cause find to exit(2) with the arg as the exit status. Useful for finding the first instance of something: find . -type f -newer ../src.tar.gz -exit 0 echo hi this will make find abort with a zero exit status early upon finding a file newer

Re: RFC: -exit option for find(1)

2004-07-16 Thread Alfred Perlstein
I'm up too late, this doesn't work because find returns success whenever it successfully runs thought everything. Perhaps the primary change to just -exit which would make find exit successfully, and if the primary is never encountered (ie. our find logic never hits it) find would exit with a

Re: RFC: -exit option for find(1)

2004-07-16 Thread Denis Antrushin
Alfred Perlstein wrote: I'm up too late, this doesn't work because find returns success whenever it successfully runs thought everything. Perhaps the primary change to just -exit which would make find exit successfully, and if the primary is never encountered (ie. our find logic never hits it)

Re: RFC: -exit option for find(1)

2004-07-16 Thread Peter Pentchev
On Fri, Jul 16, 2004 at 11:58:07AM +0400, Denis Antrushin wrote: Alfred Perlstein wrote: I'm up too late, this doesn't work because find returns success whenever it successfully runs thought everything. Perhaps the primary change to just -exit which would make find exit successfully, and if

Re: RFC: -exit option for find(1)

2004-07-16 Thread Peter Pentchev
On Fri, Jul 16, 2004 at 05:28:57PM +0300, Peter Pentchev wrote: On Fri, Jul 16, 2004 at 11:58:07AM +0400, Denis Antrushin wrote: Alfred Perlstein wrote: I'm up too late, this doesn't work because find returns success whenever it successfully runs thought everything. Perhaps the primary