Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know some useful Bash shell shortcuts, and I am wondering if there are others. The ones I know:

  • CTRL + W: delete until beginning of word
  • CTRL + U: delete until beginning of line
  • Up / Down: navigate between previous commands

What I am especially curious are the following:

  • deleting until first "/" symbol or until the point CTRL + Left would go back
  • Searching in previous posts

And any other useful shortcuts, if any.

share|improve this question

closed as not constructive by Sathya Mar 5 '12 at 11:44

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

up vote 6 down vote accepted

All this can be found in the bash man page (or type man bash in a shell)

Info per section:

and some more

share|improve this answer

The keyboard shortcuts available to you depend on whether you're using bash in emacs mode (the default) or in vi mode. You can find out which mode you're using by executing

set -o

Look in the resulting list for the line beginning "vi" and see if it is "on" or "off". Then execute

man bash

and read the section on READLINE. There you will find description of at least those commands (what you call shortcuts) available in emacs mode.

share|improve this answer

Yyou can undo tab completion with Esc Backspace.

share|improve this answer
Do you mean Esc or do you mean Backspace or do you mean pressing both? – Tom Wijsman Mar 5 '12 at 0:43

Alt+. to insert the last argument of the previous command.

Ctrl+r to search your history (though it's flaky)

History expansion in general (using !)

share|improve this answer

Not the answer you're looking for? Browse other questions tagged .