Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
vi-history-search(forward|backward) vicmd mappings
- X-seq: zsh-workers 37748
- From: Larry Hynes <larry@xxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: vi-history-search(forward|backward) vicmd mappings
- Date: Sat, 23 Jan 2016 23:30:07 +0000 (UTC)
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- Reply-to: Larry Hynes <larry@xxxxxxxxxxxxxx>
Hullo
The default vicmd mappings for
vi-history-search-forward (?)
and
vi-history-search-backward (/)
have confused me.
vi(m)-like behaviour is always to have '/' search forward and
'?' search backward.
Say my, notional, .zhistory file contains:
foo
bar
baz
qux
The search appears to begin at the last line 'qux' - as if the
history file is read in as 'vi +G .zhistory' - so to search
backwards for 'foo', I would - in vi - enter '<ESC>?' and, once
there, enter '/' to search forwards for 'baz' but it seems to be
the opposite in zsh.
In fact, if one enters '<ESC>?' on a zsh command line with
'bindkey -e' in effect the mini-buffer prompt becomes '/' to
signify a forward search, and '<ESC>/' produces a '?' to signify
a backward search, so I propose that the default mappings are,
perhaps, backwards?
Or am I missing something?
Messages sorted by:
Reverse Date,
Date,
Thread,
Author