How many times do you find yourself using arrow keys to scroll to the beginning or the end of line of the command line in bash terminal? Do you use backspace to delete every character of what you type to clear the command line? Well, if you answer “yes” to any of the two questions, continue reading.
I, myself, have been doing this a lot because I couldn’t remember the shortcut keys to do those tasks. So, I decided to write them here as a reference that could be referred to in the future. You can easily find the same or even thorough information on the web.
|Useful Shortcut Keys|
|Key sequence||What it does|
|Ctrl + U||Delete to the end of line|
|Alt + D||Delete to the end of current word|
|Alt + Backspace||Delete to the start of current word|
|Ctrl + A||Move to the start of line|
|Ctrl + E||Move to the end of line|
|Ctrl + Left Arrow||Move one word to the left|
|Ctrl + Left Arrow||Move one word to the right|
I hope those shortcuts could save you some time and the fingers from getting sore.