Advanced readline settings for bash in Terminal

Sep 04, '07 07:30:00AM

Contributed by: Anonymous

The bash shell used in the Terminal application can be tweaked a little for better interactive experience, by saving the following lines as .intputrc in your home directory:

set editing-mode vi
set show-all-if-ambiguous on
set completion-ignore-case on
set meta-flag on
set convert-meta off
set output-meta on
set bell-style visible
To be more precise, the .inputrc file changes some default settings for the readline library, which the bash shell uses when being used in interactive mode. For more options, see the readline man page. If you are more used to the emacs keybindings to edit the command line, omit the editing-mode line in the .inputrc file.

[robg adds: We've run a number of these before in separate hints, but there are a couple of new ones in this list. For a list of all the possible variables and an explanation of what each controls, type man bash, then press the forward-slash (/) to search, and type Readline Variables as the search term (capitalization counts).]

Comments (8)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20070831153033300