Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: rm -r



On Tue, Dec 21, 1999 at 07:52:29PM +0100,
fg <francis@xxxxxxxxxxxxxxxx> wrote:
> 
> Andre Pang <andrep-ml@xxxxxxxxxxx> writes:
> 
> > 
> >     rm -f **/*.o(^/) will work if you've doing 'setopt EXTENDED_GLOB', too. 
> > (That'll remove all files which end in .o recursively, and exclude all *.o
> > files which are directories).
> > 
> 
> Gee, this makes me look at "find" like an easy-to-use program ;)

I'd say
ls **/*(.)
is much easier than
find . -type f -exec ls {} \;
You just need a little bit of experience with zsh's extended globbing.
(I hardly use find any more)

YMMV :)

> BTW, whats the argument limit for zsh?

jean-luc@picard (tty11) ~> /bin/echo $(repeat 32766 echo -n  "x " )
[lots of "x x x x "]
jean-luc@picard (tty11) ~> /bin/echo $(repeat 32767 echo -n  "x " )
zsh: argument list too long: /bin/echo

Ah, the limit is at 32766 arguments. (On Linux-i386)
Here's the few situations where I need find again... :)

Question to zsh-workers (Cc-ed):
Is there a special reason why only 32766 arguments are allowed? (that
is, 32766+1, the executable name, so - an unsigned short seems to be
used for counting the arguments - why not an int? Would be 2147483646
arguments on Linux)
(I currently don't read zsh-workers, so please Cc me or zsh-users if you
reply to this question. thanks)

CU,
Thomas

-- 
 Thomas Köhler Email:   jean-luc@xxxxxxxxxxxxxxxxx   | LCARS - Linux for
     <><        WWW:  http://home.pages.de/~jeanluc/ | Computers on All
                IRC:             jeanluc             | Real Starships
   PGP public key: http://www.mayn.de/users/jean-luc/PGP-Public.asc



Messages sorted by: Reverse Date, Date, Thread, Author