Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Possible Duplicate:
Tab-completion with directories/links

when I've a symlink foo linking to a directory bar/ and I start typing f and hit tab, it completes to foo but I'd like to complete it to foo/ so I can immediately add the next character for further completes. How can I do that?

share|improve this question

marked as duplicate by studiohack Apr 16 '11 at 18:42

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

add comment

2 Answers

up vote 18 down vote accepted

Enable the mark-symlinked-directories option for readline.

  1. Edit ~/.inputrc:

    set mark-symlinked-directories on
    
  2. Press C-x, C-r to reload the settings.

See section READLINE in the manual page of bash for further documentation.

share|improve this answer
    
Thank you so much, I've been dealing with the differences between OSX (defaults to on) and Linux (defaults to off) for months, and I finally got fed up enough to google it! You're my new hero. :) –  staticfloat Aug 7 '13 at 0:56
add comment

I don't know if you can do it exactly as you've described, but if you hit tab twice, it should complete the exapansion.

share|improve this answer
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.