Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Strange parsing bug(?)
- X-seq: zsh-workers 25787
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: "Richard Hartmann" <richih.mailinglist@xxxxxxxxx>, "Zsh hackers list" <zsh-workers@xxxxxxxxxx>
- Subject: Re: Strange parsing bug(?)
- Date: Tue, 30 Sep 2008 23:06:14 -0700
- In-reply-to: <2d460de70809301756j71effaa9waa6b1a1d0736d9b9@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <2d460de70809301756j71effaa9waa6b1a1d0736d9b9@xxxxxxxxxxxxxx>
On Oct 1, 2:56am, Richard Hartmann wrote:
}
} Of course, I might have stumbled onto a hidden feature, but if that
} is the case, I would argue that this is extremely against the
} expectation of most users.
It's not a hidden feature, but it is a feature. Doc says:
If the shell encounters the character sequence `!"' in the input,
the history mechanism is temporarily disabled until the current list
(see *Note Shell Grammar::) is fully parsed. The `!"' is removed
from the input, and any subsequent `!' characters have no special
significance.
If you don't want ! to be a history character, setopt nobanghist. If
you do want it to be a history character, then ... get used to using
single quotes instead of double, I guess, because history doesn't
expand in single quotes.
(Aside: I think it's actually the first character of $histchars and
then a double quote that has this effect, so the doc could be better.)
Messages sorted by:
Reverse Date,
Date,
Thread,
Author