title: How to enable tab-completion of command line switches in bash?
body: <p>With <code>bash</code>, I can complete a command with TAB. Normally, it should also complete the command line switches: e.g. when I typed:  </p>
  
  <pre><code>java -
  </code></pre>
  
  <p>it should show me the possibilities.  It does not. How can I enable this preview?</p>
  
  <p>See also <a href="https://stackoverflow.com/questions/776071">Surprise! the shell suggests command line switches</a></p>