Table of Contents

inputrc (Readline)

File: ~/.inputrc

Readline configuration — applies to bash and any other program using the GNU Readline library.

Completion

set show-all-if-ambiguous on     # show completions without needing Tab twice
set completion-ignore-case on    # case-insensitive completion
set completion-map-case on       # treat - and _ as equivalent
set colored-stats on             # colour-code completion types
set colored-completion-prefix on
set visible-stats on             # show file type indicators
set mark-symlinked-directories on

History Navigation

Up/down arrows search history by the prefix already typed:

"\e[A": history-search-backward
"\e[B": history-search-forward

Tab Behaviour

Tab cycles through completions (menu-complete); Shift-Tab goes backward:

TAB: menu-complete
"\e[Z": menu-complete-backward

Key Reference

Binding Action
Ctrl-A Beginning of line
Ctrl-E End of line
Ctrl-K Kill to end of line
Ctrl-U Kill to beginning of line
Ctrl-Y Yank (paste)
Ctrl-R Reverse history search
Ctrl-L Clear screen
Ctrl-T Transpose characters
Ctrl-W Kill word backward
Ctrl-Left/Right Move by word
Alt-U Uppercase word
Alt-L Lowercase word
Alt-C Capitalize word

See Also