Bash (Unix shell) keyboard shortcuts

Bash (Unix shell)

Zeynel Abidin Öztürk -
14 months ago
- Shortcuts
Ctrl + C

Kill current foreground process running in the terminal

Ctrl + Z

Suspend the current foreground process running in bash

Ctrl + D

Close the bash shell

Ctrl + L

Clear the screen

Ctrl + S

Stop all output to the screen. This can be useful when running commands with very long output, but you don't want to stop the command with Ctrl + C

Ctrl + Q

Resume output to the screen after stopping it with Ctrl + S

Ctrl + A

Go to the beginning of the line

or Home
Ctrl + E

Go to the end of the line

or End
Ctrl + B

Go left one character

Alt + F

Go right one word

Ctrl + F

Go right one character

Ctrl + X then X

Move between the beginning of the line and the current position of the cursor. This allows you to change something and return to original position

Ctrl + D

Delete the character under the cursor

or Del
Alt + D

Delete all characters after the cursor on the current line

Ctrl + H

Delete the character before the cursor

or ⬅ Backspace
Alt + T

Swap the current word with the previous word

Ctrl + T

Swap the last two characters before the cursor with each other

Ctrl + _

Undo your last key press. It can be used multiple times

Esc + T

Swap the last to words before the cursor

Ctrl + W

Cut the word before the cursor and add it to the clipboard

Ctrl + K

Cut the part of the line after the cursor and add it to the clipboard

Ctrl + U

Cut the part of the line before the cursor and add it to the clipboard

Ctrl + Y

Paste the last thing you cut from the clipboard. The y here stands for “yank”

Alt + U

Capitalize every character from the cursor to the end of the current word, converting the characters to upper case

Alt + L

Uncapitalize every character from the cursor to the end of the current word, converting the characters to lower case

Alt + C

Capitalize the character under the cursor. Your cursor will move to the end of the current word.

⭾ Tab

Automatically complete the file, directory, or command you’re typing

Ctrl + P

Go to the previous command in the command history

or
Ctrl + N

Go to the next command in the command history

or
Alt + R

Revert any changes to a command you've called from your history, if you've edited it

Ctrl + R

Recall the last command matching the characters you provide. Press this shortcut and start typing to search your bash history for a command

Ctrl + O

Run a command you found with Ctrl + R

Ctrl + G

Leave history searching mode without running a command


Share this page on:

Program information

Program name: Bash (Unix shell) Bash (Unix shell) (System tools)

Bash is a Unix shell and a command language. First released in 1989, it has been distributed widely as the default login shell for most Linux distributions and Apple's macOS. A version of Bash can also be installed for Windows 10.

Web page: gnu.org/software/bash

Last update: 11 Nov 2019

Shortcut count: 39

How easy to press shortcuts: 85%

Platform detected: Windows or Linux (not macOS)

Similar programs


  1. Grand Theft Auto VGrand Theft Auto V
    74459   
  2. Keyboard symbolsKeyboard symbols
    56404    1
  3. Apex Legends (PC)Apex Legends (PC)
    42104   
  4. The Sims 4The Sims 4
    41765    3
  5. Euro Truck Simulator 2Euro Truck Simulator 2
    37552   
  6. DiscordDiscord
    37477   
More keyboard shortcuts...

Advertisement

Join our mailing list!

Your email is kept private and we don't spam.

barabu33 says: 19 days ago 10/29/2019 10:50 PM
Superb! Men that's what one should learn! Magnifique!

Reply