Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: var expansion in glob pattern? - s/end/done/ !
- X-seq: zsh-users 4769
- From: Sven Guckes <guckes@xxxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: var expansion in glob pattern? - s/end/done/ !
- Date: Sun, 24 Mar 2002 01:12:49 +0100
- In-reply-to: <1020323193618.ZM28746@xxxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20020323185649.GA12320@xxxxxxxxxxxxxxxxxxxxxx> <1020323193618.ZM28746@xxxxxxxxxxxxxxxxxxxxxxx>
* Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> [2002-03-23 19:36]:
> On Mar 23, 7:56pm, Sven Guckes wrote:
> } $ for i in 1 2 3 4 5 10 15 20 25 30 35 40 35 40 45 50; do
> } ls *(.Lk-$i)|wc -l
> } end
> } zsh: parse error near `end'
>
> You need "done" rather than "end", there.
$ for i in 1 2 3 4 5 10 15 20 25 30 35 40 35 40 45 50; do
ls *(.Lk-$i)|wc -l
done
9
211
642
1298
2015
3331
3882
4188
4365
4493
4595
4670
4595
4670
4716
4757
now it works! :-)
> There's nothing wrong with the glob expression --
> except that passing it as the argument to "ls" may do
> the wrong thing when there are no matches at all.
good point!
> Of course note that the files smaller than 50k
> includes all the files smaller than 45k, and so on ...
yep, that's a feature. :-)
Sven
Messages sorted by:
Reverse Date,
Date,
Thread,
Author