Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top


I have heard that the readline module is reading ~/.inputrc and that is how it changes the behaviour of keystrokes under programs such as bash.


How can I reload this after editing to see the changed behaviour without restarting my terminal program?

share|improve this question
Background (not wrong). – Dennis Williamson Feb 3 '11 at 16:03
Is there a way to call Readline to reload the history? Like xmonad ----recompile && xmonad --restart for reloading XMonad? – Ehtesh Choudhury Apr 19 '12 at 0:56
I came here looking for how to load .inputrc with a command. – dfrankow Feb 22 '13 at 17:23
Simply restart Bash. – Kusalananda Jun 20 at 14:16
@Kusalananda, it seems that you have not read the question properly "How can I reload this after editing to see the changed behaviour without restarting my terminal program?" – Captain Lepton Jun 21 at 9:19
up vote 42 down vote accepted

By default, C-x C-r is bound to re-read-init-file.

See the Bash Reference Manual for explanation.

share|improve this answer
This doesn't work for me. I tried a different mapping in the .inputrc file and also no luck: "\eX\eR": re-read-init-file Any suggestions? – Captain Lepton Feb 8 '11 at 12:36
@Captain Actually, it does, except it does not clear keystrokes that were deleted in the meantime. If you e.g. add some, they are loaded. Your only solution for these is a new bash -l (shell that behaves like a login shell) that is freshly initialized. – Daniel Beck Apr 25 '11 at 10:45

In .inputrc first choose your binding and after bind the re-read-init-file function:

set editing-mode vi
"\C-x\C-r": re-read-init-file

Press CTRL and x, release both, press CTRL and r.

share|improve this answer

You can also reload new entries from command line using bind -f ~/.inputrc. That will load the entries in .inputrc. Note that it just does a load, not a "reload" - so it doesn't reset any lines you happen to have removed from the .inputrc.

To quickly test from a clean slate, just run bash then work inside that new nested shell (or start a new terminal).

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .