.inputrc stopped working

I’m trying to bite the bullet and move from bash to zsh in order to avoid further pain in the future as Apple are phasing out Bash on the mac.

A major feature that I use a lot on bash is search completion in .inputrc. Zsh broke this for me and using command line is like pulling teeth without it ie in bash you woul dadd the following to .inputrc

“\e[A”: history-search-backward
“\e[B”: history-search-forward
“\e[C”: forward-char
“\e[D”: backward-char

In zsh this not longer works as expected. To get normal behavior back I had to add the following to .zsh

bindkey “^R” history-incremental-search-backward
bindkey “\e[A” history-beginning-search-backward
bindkey “\e[B” history-beginning-search-forward

Leave a Reply

Your email address will not be published. Required fields are marked *