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

Weird bug with "bindkey" in a function



I was playing around with something and wrote the following little
function:

bindfoo () {
        bindkey -v
        bindkey "[A" up-line-or-history
        bindkey "[B" down-line-or-history
        bindkey "[C" forward-char
        bindkey "[D" backward-char
        bindkey -r '\e[A'
        bindkey -r '\e[B'
        bindkey -r '\e[C'
        bindkey -r '\e[D'
        bindkey
        bindkey -e
}

The weird thing is, if any of the "bindkey" commands in that function fails
(e.g. with "bindkey: in-string is not bound") then the ENTIRE FUNCTION exits.

What the devil is up with that?

zsh 3.0.5

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



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