Re: How to conditionally search?

2009-11-27 Thread Peng Yu
On Fri, Nov 27, 2009 at 2:54 PM, Eric Blake wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > According to Peng Yu on 11/27/2009 8:38 AM: >>> find . -name '*.sh' -o -name '*.py' >>> >>> ... do what you had in mind? >> >> No. This is not what I want. This will give me all the .sh and .py

[bug #27328] find-4.5.5 -exec + segfaults in quotearg_buffer_restyled()

2009-11-27 Thread James Youngman
Follow-up Comment #3, bug #27328 (project findutils): Essentially there was a bug in the code that was supposed to deal with the situation where exec fails due to an over-long command line. Since the code tries not to exceed ARG_MAX anyway, this code was rarely exercised and so nobody noticed t

Re: How to conditionally search?

2009-11-27 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Peng Yu on 11/27/2009 8:38 AM: >> find . -name '*.sh' -o -name '*.py' >> >> ... do what you had in mind? > > No. This is not what I want. This will give me all the .sh and .py > files. But if there is a .py file and a .sh file with the sa

Re: How to conditionally search?

2009-11-27 Thread Peng Yu
On Fri, Nov 27, 2009 at 6:19 AM, James Youngman wrote: > On Wed, Nov 25, 2009 at 3:56 AM, Peng Yu wrote: >> I want to search for all '.py' files in a directory (recursively). >> However, if there is a '.sh' file in the same directory where a '.py' >> is in, the '.sh' file rather than the '.py' fi

Re: How to conditionally search?

2009-11-27 Thread James Youngman
On Wed, Nov 25, 2009 at 3:56 AM, Peng Yu wrote: > I want to search for all '.py' files in a directory (recursively). > However, if there is a '.sh' file in the same directory where a '.py' > is in, the '.sh' file rather than the '.py' file will be returned. > Would somebody let me know how to do s