Keyboard shortcuts in Fish

Fish has a lot of useful keyboard shortcuts that can be used to edit or change the commandline. The shortcuts I find useful are:

  • Ctrl+c: Clear the command line
  • Ctrl+l: Clear the terminal screen and show a fresh command prompt
  • Ctrl+w: Delete the word to the left of the cursor. This is useful for cases where you use Fish to bring back an old command and want to just change the last parameter.
  • Alt+Left or Alt+Right: Move back and forward in directory history. The PWD shown in the prompt autoupdates while you press these keys. Just stop when you have reached the directory you want. This is a killer feature cause it makes switching back and forth between directories so easy!

Tried with: Fish 2.0.0 and Ubuntu 14.04

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.