* Bindings in .zshrc
@ 2000-01-04 12:12 Hrvoje Niksic
2000-01-04 15:07 ` Zefram
0 siblings, 1 reply; 3+ messages in thread
From: Hrvoje Niksic @ 2000-01-04 12:12 UTC (permalink / raw)
To: zsh-workers
I want M-p and M-n bound to history-beginning-search-backward and
history-beginning-search-forward respectively, but it doesn't seem to
work in recent versions of zsh.
Zsh version is 3.1.6-pws-12 from Debian potato. A detailed recipe to
repeat the problem follows.
$ mkdir tst
$ cat > tst/.zshrc
echo start
bindkey '\ep' history-beginning-search-backward
bindkey '\en' history-beginning-search-forward
echo end
^D
$ ZDOTDIR=~/tst zsh
start
end
mraz% bindkey -e # new zsh, use Emacs-style bindings
mraz% bindkey
...
"^[n" history-search-forward
"^[p" history-search-backward
...
Obviously, the bindings didn't take effect, although .zshrc is read.
If I type it manually, it works:
mraz% bindkey '\ep' history-beginning-search-backward
mraz% bindkey '\en' history-beginning-search-forward
mraz% bindkey
...
"^[n" history-beginning-search-forward
"^[p" history-beginning-search-backward
...
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Bindings in .zshrc
2000-01-04 12:12 Bindings in .zshrc Hrvoje Niksic
@ 2000-01-04 15:07 ` Zefram
2000-01-04 15:23 ` Hrvoje Niksic
0 siblings, 1 reply; 3+ messages in thread
From: Zefram @ 2000-01-04 15:07 UTC (permalink / raw)
To: Hrvoje Niksic; +Cc: zsh-workers
Hrvoje Niksic wrote:
>Obviously, the bindings didn't take effect, although .zshrc is read.
Looks like you're binding those keys in the vi keymap. Do `bindkey -e'
first, in the .zshrc, to select the Emacs keymap.
-zefram
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Bindings in .zshrc
2000-01-04 15:07 ` Zefram
@ 2000-01-04 15:23 ` Hrvoje Niksic
0 siblings, 0 replies; 3+ messages in thread
From: Hrvoje Niksic @ 2000-01-04 15:23 UTC (permalink / raw)
To: Zefram; +Cc: zsh-workers
Zefram <zefram@fysh.org> writes:
> Hrvoje Niksic wrote:
> >Obviously, the bindings didn't take effect, although .zshrc is read.
>
> Looks like you're binding those keys in the vi keymap.
Oh. Yes, you're right. In fact, I do have `bindkey -e' in my .zshrc,
but at the wrong place, after the bindkeys. When I move it in front
of them, things work out nicely.
Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2000-01-04 15:24 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-01-04 12:12 Bindings in .zshrc Hrvoje Niksic
2000-01-04 15:07 ` Zefram
2000-01-04 15:23 ` Hrvoje Niksic
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).