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

On my Ubuntu machine, I can do this

emacs $(which first-part-of-executable<tab>

and bash will tab-complete the full executable name. I enabled this myself by adding

complete -c which

to my .bashrc, because I only want which to complete with executable names.

For some reason, on my RHEL5 machine, the tab completion works for which within the $(, but then moves back to filename completion for the executable.

How can I make bash complete which within parentheses?

share|improve this question

You must log in to answer this question.

Browse other questions tagged .