PDA

View Full Version : How the autocomplete <TAB> works?



IP
03-19-2004, 10:53 PM
Hello all.

KNOPPIX "autocomplete" more than a regular distribution. I mean that KNOPPIX autocomplete apt-get in<TAB> to install and apt-get install <TAB> to all the installed packages. It also autocomplete gcc -ped<TAB> to -pedantic.

How can I use this nice and useful autocomplete in a regular Debian or Fedora System?

Thanks!

Yuval Tanny.

chrisb
03-20-2004, 10:07 PM
I see that the environment vars:
BASH_COMPLETION=/etc/bash_completion
BASH_COMPLETION_DIR=/etc/bash_completion.d
are set on Knoppix.


man bash and search for /Programmable Completion/ for the gory details.

IP
03-20-2004, 10:59 PM
OK! YEA!
I search in google for BASH_COMPLETION_DIR and found this:
http://www.unixwerk.de/linux/slack/bash_completion
I search a fedora package for this. I found that a bash-completion in my apt-get, I installed it and its work!
This package is from here:
rpm http://apt.sw.be redhat/fc1/en/i386 dag

I hope it is also so easy in debian.

Thank you!