Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: -prefix conditional expression operator
- X-seq: zsh-users 14583
- From: Greg Klanderman <gak@xxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Re: -prefix conditional expression operator
- Date: Wed, 18 Nov 2009 14:53:37 -0500
- In-reply-to: <091118004539.ZM10146@xxxxxxxxxxxxxxxxxxxxxx> (Bart Schaefer's message of "Wed, 18 Nov 2009 00:45:39 -0800")
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <19203.36741.98177.266860@xxxxxxxxxxxxxxxxxx> <091118004539.ZM10146@xxxxxxxxxxxxxxxxxxxxxx>
- Reply-to: gak@xxxxxxxxxxxxxx
>>>>> On November 18, 2009 Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> You've got the right pattern syntax, but the patterns must be quoted:
> [[ -prefix '(\\|)\^/' ]]
> Module-supplied operators like -prefix can't change the shell's basic
> syntax rules.
Ahh makes perfect sense.. thanks! I'd kinda already figured that out
without fully appreciating it, because when I wanted to match '^/', I
needed to use '\$/' (without the quotes). So I really want '(\\|)^/'
(including the quotes this time).
Greg
Messages sorted by:
Reverse Date,
Date,
Thread,
Author