Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Various notes on KSH_GLOB
- X-seq: zsh-workers 31435
- From: Christian Neukirchen <chneukirchen@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Various notes on KSH_GLOB
- Date: Thu, 30 May 2013 16:30:45 +0200
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- Sender: chris@juno
Hi,
I tried using KSH_GLOB instead of EXTENDED_GLOB recently (because I
really dislike the re-interpretation of ^. What's the benefit over
typing *~?)
However, I stumbled on some problems:
% zsh -f
juno% zsh --version
zsh 5.0.2 (x86_64-unknown-linux-gnu)
juno% mkdir -p v/v/v/v/v
juno% setopt kshglob
juno% echo *(v|v)
v
juno% echo *(v)
zsh: unknown file attribute
juno% echo *(v|v/)
zsh: bad pattern: *(v|v/)
juno% setopt extendedglob
juno% echo (v/)#
v/ v/v/ v/v/v/ v/v/v/v/ v/v/v/v/v/
I realize that both mksh and ksh93 neither support directory recursion
with *() (but this would be nice to have, IMO, at last with the explicit
/), which probably only makes this a documentation bug:
>> *(...) Match any number of occurrences. (Like `(...)#'.)
Thoughts?
(Perhaps I just need a widget to type \^ when I type ^ after whitespace...)
--
Christian Neukirchen <chneukirchen@xxxxxxxxx> http://chneukirchen.org
Messages sorted by:
Reverse Date,
Date,
Thread,
Author