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

If I typer unrar-nonfree and double tap tab, I get the usual autocomplete result:

michaelxu@michaelxu-server:~$ unrar-free /         initrd.img.old    mxx.lock          tmp/
bin/            nohup.out         usr/
boot/             lastbackup.txt    proc/             var/
cdrom/            lib/              root/             vmlinuz
dev/              lost+found/       sbin/             vmlinuz.old
etc/              media/            selinux/
home/             mnt/              srv/
initrd.img  sys/

However if i type unrar (the symlink of unrar-nonfree created by update-alternatives)then double tap tab, I get the options instead:

michaelxu@michaelxu-server:~$ unrar
e   l   lb  lt  p   t   v   vb  vt  x

Does this have to do with symlinks? Is this a bug or a featrue?

share|improve this question
Ooops i jsut realized this was a bad question – agz May 5 '13 at 6:32
I don't think it's such a bad question. Why don't you just post an answer yourself? I assume you had to include unrar-free into the unrar completion function -- that could be a good info for somebody else. – mpy May 5 '13 at 8:25
Actually it wasnt a bad question :D, I still haven't solved the issue. – agz May 11 '13 at 6:32

I solved it with

set mark-symlinked-directories on

in ~/.inputrc Solution is from

share|improve this answer
No more double tab: set show-all-if-ambiguous on is also handy – michalzuber May 22 '13 at 7:45

If you use bash-completions, just edit the file /usr/share/bash-completion/completions/unrar. Close to the end of the file there is a line

complete -F _unrar unrar

Just add another one like that

complete -F _unrar unrar-free

Don't forget to open up a new terminal, so that the filechange gets read in.

share|improve this answer
You should contact the maintainers of bash-completion, so this is included by default -- if unrar-free is a common tool they probably will do it. – mpy May 11 '13 at 8:25

You must log in to answer this question.

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