Show Menu
Cheatography

Basic Bash Keyboard Shortcuts by

Bash (Bourne-again shell) is a command language and an UNIX shell. This sheet show the basics commands to use it with some links to get the concepts. Please comment your feedback and rate it.Last Update `2020-09-27`.

Basic Shortcuts

(TAB)
complete: Attempt to perform completion on the text before point. [more]
(C-j)
Newline: Send a newline (\n)
(C-c)
interrupt (kill): The current foreground process running in in the terminal. [more]
(C-d)
end-of-file (EOF): If there are no chars on the line, Readline returns EOF
(C-z)
susp­end: stop the program execution. fg to resume, jobs -l to list and kill <id­> to close it [more]
(C-p)
previous-history: Move ‘backward’ through the history list, fetching the previous command.
(C-n)
next-history: Move ‘forward’ through the history list, fetching the next command.
(C-r)
reverse-search-history: Search 'backward' through the history. This is an incremental-search.
(C-a)
begi­nni­ng-­of-­line: Move to the start of the line.
(C-e)
endi­ng-­of-­line: Move to the end of the line
(M-b)
back­war­d-w­ord: Move backward a word
(C-b)
back­war­d-c­har: Move backward a character.
(M-f)
forw­ard­-wo­rd: Move forward a word
(C-f)
forw­ard­-ch­ar: Move forward a character.
(C-u)
unix­-li­ne-­dis­card: Kill 'backward' from the cursor to the beginning of the current line.
(C-k)
kill­-li­ne: Kill 'forward' from the cursor to the end of the current line.
(M-del)
dele­te-­bac­kwa­rd-­word: Kill the word behind point
(M-d)
dele­te-­for­war­d-w­rord: Kill from point to the end of the current word
(C-l)
clear-screen: Clear the screen, reprinting the current line at the top.
(C-x C-u)
undo: Increm­ental undo, separately remembered for each line.
(M-r)
revert-line: Undo all changes made to this line. This is like executing the undo command enough times to get back to the beginning.
(C-y)
yank: Yank the top of the kill-ring into the buffer at point. [more]
(M-y)
yank­-pop: Rotate the kill-ring, and yank the new top. You can only do this if the prior command is yank or yank-­pop.
(C-s)
transmit off (XOFF): Stops the data flow from the keyboard [more]
(C-q)
transmit on (XON): Enable the data flow and release all the info contained [more]
(C-): Control key = Ctrl
(M-): Meta key [] = Alt, [] = Opt (check Notes)
It is a loose convention that (C-) operate on chars while (M-) operate on words. [more]
‘Cut’ and ‘paste’ are more recent jargon for ‘kill’ and ‘yank’.
 

About

Last Update 2020-­09-07 | Im_tavo

Notes

For Firefox users: Cheath­ography uses a preload option to load the icons and firefox disable it by default. To enable it. Write this in the URL bar about­:co­nfig, search the netwo­rk.p­re­load option and set it true
You can find more info in this link [more]
For Mac users: The Meta key is setted to the ESC, but you can set the Opt key as well. Just open the terminal and go to
Terminal > Settings > Basic Default > Keyboard > Use option as meta key
If you need more inform­ation, read this tutorial [more]
Spanish Keyboard Mac users: There are some users that say that the config­uration of Opt key above can disable some keys like ~#¬]}\|
For Windows user There are some ways tu use the bash shortcuts in terminal. if you want to use the native powers­hell, check this page to see how to use Bash shortcuts
I really loved doing this cheats­heet, I expect that it could helps you

More Info

               

Help Us Go Positive!

We offset our carbon usage with Ecologi. Click the link below to help us!

We offset our carbon footprint via Ecologi
 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          Linux Command Line Cheat Sheet
          bash Shortcuts Cheat Sheet

          More Cheat Sheets by gamejia90

          Vimtutor Cheat Sheet