Re: -exec on find(1) broken

2007-10-10 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Marty Leisner on 10/10/2007 12:10 AM: > > Geez, thanks Brian...I've been using find for 25 years and never realized it > had > a delete option . That's because, until a few years ago, it didn't (and it is still only GNU find that has i

Re: -exec on find(1) broken

2007-10-09 Thread Marty Leisner
Brian Dessent <[EMAIL PROTECTED]> writes on Tue, 09 Oct 2007 02:51:23 PDT > Paul McFerrin wrote: > > > Well, I finally got it! > > > > find . -type f -mtime +18 -exec /bin/echo {} \; | more > > > > is the correct syntax. Now I just replace "/bin/echo" wi

RE: -exec on find(1) broken

2007-10-09 Thread Dave Korn
On 09 October 2007 08:07, Paul McFerrin wrote: > Well, I finally got it! > > find . -type f -mtime +18 -exec /bin/echo {} \; | more > > is the correct syntax. Now I just replace "/bin/echo" with "/bin/rm" > and I ready to go. Will break on paths/files with embedded spaces, use find .

Re: -exec on find(1) broken

2007-10-09 Thread Brian Dessent
Paul McFerrin wrote: > Well, I finally got it! > > find . -type f -mtime +18 -exec /bin/echo {} \; | more > > is the correct syntax. Now I just replace "/bin/echo" with "/bin/rm" > and I ready to go. That's still horribly overcomplicated and inefficient. Use "find . -type f -mtime +18" t

RE: -exec on find(1) broken

2007-10-09 Thread Alexander.Farber
Then you better use xargs: find . -type f -mtime +18 -print0 | xargs -0 rm -i > -Original Message- > [mailto:[EMAIL PROTECTED] On Behalf Of ext Paul McFerrin > find . -type f -mtime +18 -exec /bin/echo {} \; | more > > is the correct syntax. Now I just replace "/bin/echo" wi

Re: -exec on find(1) broken

2007-10-09 Thread Paul McFerrin
Well, I finally got it! find . -type f -mtime +18 -exec /bin/echo {} \; | more is the correct syntax. Now I just replace "/bin/echo" with "/bin/rm" and I ready to go. -paul Paul McFerrin wrote: Those ideas don't work either /i/mp3.$ find . -type f -mtime +18 -exec /bin/echo '\;

Re: -exec on find(1) broken

2007-10-08 Thread Paul McFerrin
Those ideas don't work either /i/mp3.$ find . -type f -mtime +18 -exec /bin/echo '\;' | more find: missing argument to `-exec' while /i/mp3.$ find . -type f -mtime +18 -exec /bin/echo ';' | more /i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \; | more both produces many emp

Re: -exec on find(1) broken

2007-10-08 Thread Gary Johnson
On 2007-10-09, Paul McFerrin wrote: > I think I'm going nuts. What am I doing wrong? Can't seem to get -exec to > work. > >/i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \{\;\} | more >find: missing argument to `-exec' >/i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \{\} | mo

Re: -exec on find(1) broken

2007-10-08 Thread Václav Haisman
Paul McFerrin wrote, On 9.10.2007 8:09: > I think I'm going nuts. What am I doing wrong? Can't seem to get -exec > to work. > >/i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \{\;\} | more >find: missing argument to `-exec' >/i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \{\

-exec on find(1) broken

2007-10-08 Thread Paul McFerrin
I think I'm going nuts. What am I doing wrong? Can't seem to get -exec to work. /i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \{\;\} | more find: missing argument to `-exec' /i/mp3.$ find . -type f -mtime +18 -exec /bin/echo \{\} | more find: missing argument to `-exec' /