8.3 Readline Init File

Although the Readline library comes with a set of Emacs-like keybindings installed by default, it is possible to use a different set of keybindings. Any user can customize programs that use Readline by putting commands in an inputrc file, conventionally in their home directory. The name of this file is taken from the value of the shell variable INPUTRC. If that variable is unset, the default is ~/.inputrc. If that file does not exist or cannot be read, Readline looks for /etc/inputrc. The bind builtin command can also be used to set Readline keybindings and variables. See Bash Builtin Commands.

When a program that uses the Readline library starts up, Readline reads the init file and sets any variables and key bindings it contains.

In addition, the C-x C-r command re-reads this init file, thus incorporating any changes that you might have made to it.