Linux [shell command]
Introduction
This will be a memo for learning.
This time, we will learn frequently used shell commands (shortcut keys).
Move cursor
command |
Contents |
Ctrl+f |
Move to next one character |
Ctrl+b |
Move one character forward |
Ctrl+a |
Move to the beginning of the line |
Ctrl+e |
Move to end of line |
Meta+f(esc+f) |
Move to the next word |
Meta+b(esc+b) |
Move one word forward |
Editing strings
command |
Contents |
Ctrl+h |
Delete one character to the left of the cursor |
Ctrl+d |
Delete one character in the cursor part |
Ctrl+w |
Delete the word at the cursor position (the part before the cursor) |
Ctrl+u |
Delete from the cursor position to the beginning of the line |
Ctrl+k |
Delete from the cursor position to the end of the line |
Ctrl+y |
Insert the last deleted content |
Response in case of trouble
command |
Contents |
Ctrl+c |
Forcibly terminate the command being executed |
Ctrl+l |
Erase the screen. Can also be used to clear garbled characters |
Ctrl+s |
Screen display lock (character input from the keyboard is not accepted) |
Ctrl+q |
Unlock screen display |
Completion / command history
command |
Contents |
Tab |
Command and path completion |
Ctrl+p or ↑ key |
View the previous history |
Ctrl+n or ↓ key |
See the history after one |
Ctrl+r |
Incremental search of command history |