# Bash Keybindings ## Navigation | Keybinding | Action | Shell | |---------------------------------------|-----------------------------------------|-----------| | Ctrl + a | Go to the beginning of the line | bash, zsh | | Ctrl + e | Go to the end of the line | bash, zsh | | Ctrl + f | Move one character forward | bash, zsh | | Ctrl + b | Move one character backward | bash, zsh | | Alt + f | Move one word forward | bash, zsh | | Alt + b | Move one word backward | bash, zsh | | Alt + b | Jump and mark to the beginning and back | bash, zsh | ## Line Editing | Keybinding | Action | Shell | |---------------------------------------|------------------------------------------------|-----------| | Ctrl + d | Delete forward | bash, zsh | | Ctrl + h | Delete backward | bash, zsh | | Alt + d | Delete word forward | bash, zsh | | Alt + w | Delete word backward | bash, zsh | | Alt + Backspace | Delete word backward | bash, zsh | | Ctrl + k | Delete everything to the end of the line | bash, zsh | | Ctrl + u | Delete everything to the beginning of the line | bash, zsh | | Ctrl + y | Yank (paste) last deleted item | bash, zsh | | Alt + p | Replace arg with previous command's arg | zsh | | Alt + n | Replace arg with next command's arg | zsh | | Alt + . | Yank (paste) the last command's arg | bash, zsh | | Ctrl + ? | Undo | bash, zsh | ## Signals and Symbols | Keybinding | Action | Shell | |---------------------------------|------------------------------------------|-----------| | Ctrl + c | Send SIGINT | bash, zsh | | Ctrl + \\ | Send SIGQUIT | bash, zsh | | Ctrl + z | Send XOFF/SIGTSTP | bash, zsh | | Ctrl + c | Send XON/SIGCONT | bash, zsh | | Ctrl + l | Clear the screen (similar to `clear`) | bash, zsh | | Ctrl + d | Send EOF (can be used to exit the shell) | bash, zsh | ## History | Keybinding | Action | Shell | |--------------------------------|----------------------------|-----------| | Ctrl + p | Previous command | bash, zsh | | Ctrl + n | Next command | bash, zsh | | Ctrl + r | Reverse search the history | bash, zsh | | Ctrl + s | Search the history | bash, zsh |