Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Regular expressions in zsh
- X-seq: zsh-users 15814
- From: Phil Pennock <zsh-workers+phil.pennock@xxxxxxxxxxxx>
- To: Vincent Stemen <vince.lists@xxxxxxxxxxx>
- Subject: Re: Regular expressions in zsh
- Date: Sat, 19 Feb 2011 00:48:07 -0500
- Cc: zsh-users@xxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=spodhuis.org; s=d200912; h=In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date; bh=SjXktdcZBzVKRBiCjiWQHdlxXLYRci0CUjyonjl+kZA=; b=dByccgugeB4yN2ZfB/TyL2JhvfGB3ny8mBadmnan7SQRQKgDEDzBKnbDPGI3dslUb7nZkuM8U0/llWvpSyoEQvE0W6ZHSKLSTrdgo0DUHq356w1QgugSe4U7mUE7qzxIIqIO4UWlRKzvIF5+A0amJOVM87P184aGErefEHxg0Vc=;
- In-reply-to: <20110219033809.GA72507@quark.hightek.org>
- 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: Vincent Stemen <vince.lists@xxxxxxxxxxx>, zsh-users@xxxxxxx
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <20110219033809.GA72507@quark.hightek.org>
On 2011-02-18 at 21:38 -0600, Vincent Stemen wrote:
> I was very delighted to discover today that zsh now supports full
> regular expressions in conditional statements, even using the Perl
> like =~ syntax. That was one thing that I always wished zsh had.
>
> My compliments to the chef :-).
zsh has had -pcre-match for a very long time; it's only the =~ operator
which is newish; note that if you're a Perl fan, then you might:
setopt REMATCH_PCRE
to use PCRE regexps instead of the system regexp library's extended
regexp syntax.
You're welcome. :) [though I can't claim credit for the original
-pcre-match].
Messages sorted by:
Reverse Date,
Date,
Thread,
Author