Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

history-incremental-search-backward string argument regression


I was trying to let ^r prefill the incremental search minibuffer with the
current buffer contents.

According to the manual:

When called from a widget function by the zle command, the incremental
search commands can take a string argument.  This will be treated as a
string of keys, as for arguments  to  the  bindkey  and used as initial
input for the command.  Any characters in the string which are unused by
the incremental search will be silently ignored.  For example,

zle history-incremental-search-backward forceps

search backwards for forceps, leaving the minibuffer containing the string

I've created a widget calling this,  but the minibuffer stayed empty. When
I manually type something into the minibuffer, it does the usual search,
but when I then press ^r again to find the next result, I get an empty
minibuffer again, instead of the next result.

zsh 5.2 (x86_64-ubuntu-linux-gnu) (Ubuntu 17.10 default): broken
zsh 5.4.2-dev-0 (x86_64-unknown-linux-gnu) (newest git on Ubuntu 17.10):
zsh 4.3.11 (x86_64-redhat-linux-gnu) (CentOS 6.4): WORKS


Messages sorted by: Reverse Date, Date, Thread, Author