As a SysAdmin/DevOps, I spend a lot of my day in the terminal.

Here are my favorite shortcuts!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
2 answers

The below two are particularly useful if you have a very long command.

  • Delete everything from the cursor to the end of the line:
Ctrl + k
  • Delete everything from the cursor to the start of the line:
Ctrl + u
  • Delete one worked backwards from cursor:
Ctrl + w
  • Search your history backwards, this is probably the one that I use the most, it is really handy and speeds up my work-flow a lot:
Ctrl + r
  • Clear the screen, I use this instead of typing the clear command:
Ctrl + l
  • Stops the output to the screen:
Ctrl + s
  • Enable the output to the screen in case that previously stopped by Ctrl + s:
Ctrl + q
  • Terminate the current command
Ctrl + c
  • Throw the current command to background:
Ctrl + z

I use those constantly every day and it saves me a lot of time.

If I’ve missed any feel free to share them in the comments below!

To go back to the [char] character in the current line.

ctrl + alt + ] + [char]

To go forward to the [char] character on the current line.

ctrl + ] + [char]

To swap two char around the cursor position.

ctrl + t
Submit an Answer