Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Globbing question
- X-seq: zsh-users 18146
- From: Dominik Vogt <vogt@xxxxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Globbing question
- Date: Mon, 18 Nov 2013 11:45:43 +0100
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mail-followup-to: zsh-users@xxxxxxx
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- Reply-to: vogt@xxxxxxxxxxxxxxxxxx
Assuming I have a directory with some files and some
subdirectories, e.g.
subdir/
anothersubdir/
...
subdir123/
git/
file
anotherfile
I'm looking for a globbing pattern that matches all plain files in
all subdirectories except "git". The pattern
$ ls -d ^git(/)
gives me all directories except "git", but the next one produces
an error message:
$ ls -d ^git(/)/**/*(.)
zsh: bad pattern: ^git(/)/**/*(.)
So my questions are:
1. Why does this pattern not work; what am I missing?
2. What is the correct pattern for the task at hand?
(Note: The reason why I need to exclude "git" from the pattern is
that there are too many files in that directory, so I get an
"zsh: argument list too long" error.)
Ciao
Dominik ^_^ ^_^
Messages sorted by:
Reverse Date,
Date,
Thread,
Author