|
Ctrl + a
go to the start of the command line
|
|
Ctrl + e
go to the end of the command line
|
|
Ctrl + xx
(toggle) beginning of line/cursor position
|
|
Alt + b
previous word begin
|
|
Alt + f
next word end
|
|
Ctrl + f
forward one character
|
|
Ctrl + b
back one character
|
|
Alt + c
from cursor, capitalize to end of word
|
|
Alt + u
from cursor, uppercase to end of word
|
|
Alt + l
from cursor, lowercase to end of word
|
|
Alt + t
transpose word with previous word
|
|
Ctrl + t
transpose character with previous character
|
|
Ctrl + l
clear screen
|
|
Ctrl + s
stops screen output (for verbose commands)
|
|
Ctrl + q
allow screen output (undo Ctrl+S)
|
|
Ctrl + c
terminate command
|
|
Ctrl + z
suspend command/send to background (use fg to bring forward)
|
|
Ctrl + r
search history backward
|
|
Ctrl + g
escape from history search mode
|
|
Ctrl + p
previous command in history (walk back)
|
|
Ctrl + n
next command in history (walk forward)
|
|
Alt + .
last word of previous command
|
|
Ctrl + u
from cursor, delete to start of line
|
|
Ctrl + k
from cursor, delete to end of line
|
|
Ctrl + w
from cursor, delete to start of word
|
|
Alt + d
from cursor, delete to end of word
|
|
Ctrl + d
delete character under cursor
|
|
Ctrl + h
delete character before cursor
|
|
Ctrl + y
after cursor, paste cut/deleted text
|
|
!!
run last command
|
|
!foo
run most recent command starting with 'foo'
|
|
!foo:p
print most recent command starting with 'foo'
|
|
!$
last word of previous command (Alt + .)
|
|
!*
previous command without last argument
|
|
!*:p
print previous command without last argument
|
In addition to the cases of letters, I believe the last 2 bang commands are not right. !* stands for all the arguments of previous command, !*:p prints them. It does not run the previous command without arguments. Could be the version of bash?
4 stars because I think the letters should be lowercase. Great work otherwise !
Cheatography n. The art of mapping complex subjects into clear, instantly navigable reference guides.