Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: parse errors and up-line-or-history
- X-seq: zsh-workers 13015
- From: "E. Jay Berkenbilt" <ejb@xxxxxx>
- To: schaefer@xxxxxxxxxxxxxxxxxxxxxxx
- Subject: Re: parse errors and up-line-or-history
- Date: Tue, 17 Oct 2000 19:03:57 -0400
- Cc: zsh-workers@xxxxxxxxxxxxxx
- In-reply-to: <001017142111.ZM3802@xxxxxxxxxxxxxxxxxxxxxxx> (schaefer@xxxxxxxxxxxxxxxxxxxxxxx)
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
- References: <200010171935.PAA14828@xxxxxxxxxxx> <001017142111.ZM3802@xxxxxxxxxxxxxxxxxxxxxxx>
> > zsh% for in *; do echo $i; done
> > zsh: parse error near `do'
> >
> > which seems entirely reasonable. If you then do ^p to fix it, you see
> > only
> >
> > zsh% for in *; do
> >
> > and not the whole command.
>
> Congratulations, you've revived the "literal vs. lexical history" debate,
> if it ever really was a debate.
>
> Zsh used to have an option to store the command history as the literal
> input text, rather than as lexical words. IIRC, it actually stored both
> and let you select which one to retrieve. The duplication was resolved
> in favor of lexical history a *very* long time ago, with the side-effect
> that anything that won't lex, doesn't make it into the history.
>
> For a partial workaround, see zsh-workers/10996.
This workaround does exactly what I want. I just bound your
zle-fetch-previous and zle-fetch-next to ^x^p and ^x^n respectively so
I get the benefits of the lexical history except when I really want
the other in which case I can specify it directly. Thanks.
Jay
Messages sorted by:
Reverse Date,
Date,
Thread,
Author