From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-workers@zsh.org
Subject: Re: Inconsistent history expansion of characters adjacent to histchar
Date: Tue, 08 Oct 2013 07:31:25 -0700 [thread overview]
Message-ID: <131008073126.ZM1910@torch.brasslantern.com> (raw)
In-Reply-To: <131007195612.ZM1029@torch.brasslantern.com>
On Oct 7, 7:56pm, Bart Schaefer wrote:
}
} In short, the history parser has always been very ad-hoc and deviates
} from its own spec in several ways.
}
} Here's a patch that fixes the unintended expansion, but it doesn't fix
} the inconsistent behavior with !& !| et al. There should probably be
} more method to this madness instead of multiple series of individual
} character comparisons.
Just to illustrate this further:
torch% print !\; print foo
zsh: event not found: \
torch% \print bar
bar
torch% print !\; print foo
print \print bar; print foo
print bar
foo
torch%
I'm wondering if backslash ought to be treated specially in more of the
history code. In particular:
torch% print !\!; print foo
zsh: event not found: \!
torch%
One might think one could use that form to search for a command line
that begins with a literal exclamation point, but no.
next prev parent reply other threads:[~2013-10-08 14:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-07 15:55 Hauke Petersen
2013-10-08 2:56 ` Bart Schaefer
2013-10-08 14:31 ` Bart Schaefer [this message]
2013-10-08 14:44 ` Peter Stephenson
2013-10-08 15:43 ` Peter Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=131008073126.ZM1910@torch.brasslantern.com \
--to=schaefer@brasslantern.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).