Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
history-incremental-search-backward and personnal zle widget
- X-seq: zsh-users 12373
- From: antho.charles@xxxxxxxxx
- To: zsh-users@xxxxxxxxxx
- Subject: history-incremental-search-backward and personnal zle widget
- Date: Sat, 29 Dec 2007 02:24:51 +0100
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:to:subject:message-id:mime-version:content-type:content-disposition:user-agent:from; bh=Aeg3qpy4KqSj68ljo5zg/qnK4FsU9xt+DcO5sSopHoU=; b=VmQyTxtsh8RZziQ51TJhAqqe3p/561ivgLR1vszvXzMu1ZiI656NuDAiDxgZi3km8+fJ/ht6fN3UrIdNEopUEKGcJT3vXdbWYwvPJjr5VRnUCbaxwdUOrk/5jtHTB2PO+pyD9/H1CcnvlzdXP2jkWod5Y5dA7yTbcvrSgcs2juk=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:to:subject:message-id:mime-version:content-type:content-disposition:user-agent:from; b=wjRpGIXchPo2sxnZZv+OuUM/K4RaGnpn/CQ5pZpc0vKid5dh8pPcW1RYeuHjXaSPLJGF0fRGTsJxK+HIyN628RpPMDvf1kfE+qAr8yqMs35M4nREec1Hy1o3cyOf+2d1yGE/oJ0R9gcoTK2k/uXWynM7yZ+faazbZYSNrXc7+PM=
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
Hi,
I find this widget from a zshrc I can't remember and I bind it to the dot key:
# just type 'cd ...' to get 'cd ../..'
rationalise-dot() {
if [[ $LBUFFER = *.. ]]; then LBUFFER+=/..
else
LBUFFER+=. fi
}
zle -N rationalise-dot
bindkey . rationalise-dot
but when I type a dot in a history-incremental-search-backward ( ^R ), it stops the
search and insert a dot in the line instead of inserting a dot in the
searched string. I found something useful in zshzle manpage:
"A restricted set of editing functions is available in the mini-buffer. An interrupt
signal, as defined by the stty setting, will stop the search and go
back to the original line. An undefined key will have the same
effect."
My question is: is there a way to keep my binded widget and use it
with history-incremental-search-backward?
--
Anthony CHARLES
Attachment:
signature.asc
Description: Digital signature
Messages sorted by:
Reverse Date,
Date,
Thread,
Author