8

I always knew you could switch between Vim and Emacs bindings for Bash by modifying .inputrc.

I'm now realizing there are actually a few different useful options I've decided to turn on including:

set bell-style none
set colored-stats On
set show-all-if-ambiguous On

The comments in /etc/inputrc on my system provide some guidance as to what is possible but not all the options are shown there.

I'm also trying man readline but all I get is a really short page describing the program.

Is there somewhere I can see all the options which can be turned on and off via .inputrc?

3
  • 2
    Readline options are listed inside man bash. Commented Jan 26, 2020 at 4:19
  • 4
    I get a really long man page with man 3 readline you many need to install some dev package to get this section 3 page. Commented Jan 26, 2020 at 9:35
  • 2
    there's also a readline-doc package in debian Commented Jan 26, 2020 at 9:38

3 Answers 3

8

You may want to check the bind Bash builtin command.

Use help bind to see the different options.

In particular, you could check the output of

  • bind -l : List names of functions.
  • bind -p : List functions and bindings in a form that can be reused as input.
  • bind -v : List variable names and values in a form that can be reused as input.
1

not certain it's complete, but the Archlinux page for readline(3) provides a fairly comprehensive list of options.

In addition to that there's the The GNU Readline Library documentation page which has a good deal on the syntax and commands. Again, hard to tell if it's comprehensive.

0

Here is the section of the Bash manual which describes the syntax of the Readline Init File. The init file is typically found at one of these locations:

  • ~/.inputrc
  • /etc/inputrc

The manual page above is part of a longer section on Command Line Editing.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.