UNIX & Linux hotkeys - Keyboard Shortcuts



CTRL + B Move the cursor backward one character.
CTRL + C Cancel the currently running command.
CTRL + D Log out of the current session.
CTRL + F Move the cursor forward one character.
CTRL + H Erase one character. Similar to pressing backspace.
CTRL + P Paste previous line and/or lines.
CTRL + S Stop all output on screen (XOFF).
CTRL + Q Turn all output stopped on screen back on (XON).
CTRL + U Erase the complete line.
CTRL + W Delete the last word typed in. For example, if you typed 'mv file1 file2' this shortcut would delete file2.
CTRL + Z Cancel current operation, move back a directory and/or take the current operation and move it to the background.


In addition to the below command line shortcuts, it is also helpful to use the alias command that allows you to specify a keyword for frequently used commands or mistakes.


~ Move to the user's home directory.
!! Repeat the line last entered at the shell. See history command for previous commands.
!$ Repeat the last argument for the command last used. See history command for previous commands.
CTRL + L Clear the terminal
reset Reset the terminal if terminal screen is not displaying correctly.
shutdown -h now Remotely or locally shut the system down.