Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh handling of non-standard if-evaluations
- X-seq: zsh-users 11154
- From: Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: zsh handling of non-standard if-evaluations
- Date: Sun, 28 Jan 2007 21:57:40 +0000
- In-reply-to: Message from Daniel Qarras <dqarras@xxxxxxxxx> of "Sun, 28 Jan 2007 11:00:17 PST." <184104.7951.qm@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
Daniel Qarras wrote:
> --- Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> > schaefer[501] [ "$VAR" == "VAL" ]; echo $?
> > zsh: = not found
> > schaefer[502] setopt no_equals
> > schaefer[503] [ "$VAR" == "VAL" ]; echo $?
> > 1
>
> Correct.
Note that "setopt nonomatch" is enough to get this to work; that allows
you to carry on using =-expansion (that's why I didn't find the problem
to begin with). It even works if you have a programme called = in your
path.
(That seems a little strange, actually. Either you'd expect == to find
a programme called =, or you'd expect == to be a normal argument without
any pattern match failure. It seems that you need to quote the second
argument: =\= does find = in the path. That strikes me as a bug.)
--
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/
Messages sorted by:
Reverse Date,
Date,
Thread,
Author