There are only four constructs allowed in the `~/.inputrc' file:
set
command within the init file. Here is how you
would specify that you wish to use vi
line editing commands:
set editing-mode viRight now, there are only a few variables which can be set; so few in fact, that we just iterate them here:
editing-mode
editing-mode
variable controls which editing mode you are
using. By default, GNU Readline starts up in Emacs editing mode, where
the keystrokes are most similar to Emacs. This variable can either be
set to emacs
or vi
.
horizontal-scroll-mode
On
or Off
. Setting it
to On
means that the text of the lines that you edit will scroll
horizontally on a single screen line when they are larger than the width
of the screen, instead of wrapping onto a new screen line. By default,
this variable is set to Off
.
mark-modified-lines
On
, says to display an asterisk
(`*') at the starts of history lines which have been modified.
This variable is off by default.
prefer-visible-bell
On
it means to use a visible bell if
one is available, rather than simply ringing the terminal bell. By
default, the value is Off
.
Control-u: universal-argument Meta-Rubout: backward-kill-word Control-o: ">&output"In the above example, C-u is bound to the function
universal-argument
, and C-o is bound to run the macro
expressed on the right hand side (that is, to insert the text
`>&output' into the line).
"\C-u": universal-argument "\C-x\C-r": re-read-init-file "\e[11~": "Function Key 1"In the above example, C-u is bound to the function
universal-argument
(just as it was in the first example),
C-x C-r is bound to the function re-read-init-file
, and
ESC [ 1 1 ~ is bound to insert the text `Function Key 1'.
Go to the first, previous, next, last section, table of contents.