emacs Mode Commands

Table 2.9 shows a complete list of emacs editing mode commands.

Table B-9. emacs Mode Commands

Command Meaning
CTRL-AMove to beginning of line
CTRL-BMove backward one character
CTRL-DDelete one character forward
CTRL-EMove to end of line
CTRL-FMove forward one character
CTRL-G

Abort the current editing command and ring the terminal bell

CTRL-JSame as RETURN
CTRL-KDelete (kill) forward to end of line
CTRL-LClear screen and redisplay the line
CTRL-MSame as RETURN
CTRL-NNext line in command history
CTRL-OSame as RETURN, then display next line in history file
CTRL-PPrevious line in command history
CTRL-RSearch backward
CTRL-SSearch forward
CTRL-TTranspose two characters
CTRL-UKill backward from point to the beginning of line
CTRL-VMake the next character typed verbatim
CTRL-V TABInsert a TAB
CTRL-W

Kill the word behind the cursor, using whitespace as the boundary

CTRL-X /

List the possible filename completions of the current word

CTRL-X ~

List the possible username completions of the current word

CTRL-X $

List the possible shell variable completions of the current word

CTRL-X @

List the possible hostname completions of the current word

CTRL-X !

List the possible command name completions of the current word

CTRL-X (Begin saving characters into the current keyboard macro
CTRL-X )Stop saving characters into the current keyboard macro
CTRL-X eRe-execute the last keyboard macro defined
CTRL-X CTRL-RRead in the contents of the readline initialization file
CTRL-X CTRL-VDisplay version information ...

Get Learning the bash Shell, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.