Comments for bash programmable completion

18 Apr 2003 17:53 ianmacd

Re: Environment Variable Completion

> I love this project. Truly a great
> time/keystroke saver. I have had one
> problem, though. Has anyone else found
> that environment variable completion no
> longer works. The way I work, I find
> that I type a lot of environment
> variable names, and the fact that Bash
> will no longer complete them is very
> annoying.


Could you be more precise about exactly what you're attempting to do here?

18 Apr 2003 13:57 wateshay

Environment Variable Completion
I love this project. Truly a great time/keystroke saver. I have had one problem, though. Has anyone else found that environment variable completion no longer works. The way I work, I find that I type a lot of environment variable names, and the fact that Bash will no longer complete them is very annoying.

31 Mar 2003 12:33 rogerk

Folder completion for mutt or mailx?
Has anybody attempted folder completion for something like mutt?

> mutt -f =foo<tab>

would list
foobar foobaz food

mailx and many other MUAs use this "=folder" syntax from the command line, so it would be useful for more than just mutt.

22 Feb 2003 05:31 zivilist

badblocks
i would like to complete the command badblocks

e.g. "badblocks -sv /dev/sda1"

because the E2fsprogs is a essential tool in every distribution

19 Feb 2003 13:09 zivilist

"rm -r" completion
I would like to have a completion to the command "rm -r".
Only directories should be listed.

13 Feb 2003 08:40 raopm

Automatic change directory
Would it be possible to add the automatic change directory feature to Bash Completion?

If a directory called /usr/local/lib/foo exists and the command line is:
$ /usr/local/lib/foo <return>

Then the action is to change to that directory instead of reporting that "/usr/local/lib/foo" is a directory.

I've used this feature in other shells. Can this be done at the command completion level or does it call for a more fundamental change in bash itself?

09 Dec 2002 11:33 ianmacd

Re: gdb

> A change to the completion of gdb that i
> forgot to submit earlier:
> change echo core* \ to compgen -f core*
> ;


Thanks. This will be in the next release.

09 Dec 2002 11:33 ianmacd

Re: gdb

> There's a "core *" missing in
> gdb:
> @line 2595
> + COMPREPLY=( $( compgen
> -W "$( echo core.* $( ps axo
> comm,pid |
>
> BTW, it would be nice, when nothing
> matches, to have it revert to old style.
> It's more annoying this way.


You can't pass both '-o filenames' and '-o default' to the complete built-in. bash's completion mechanism is inadequate in a number of ways and this is just one of them.

09 Dec 2002 11:29 ianmacd

Re: rsync suport

> is rsync suport available and if not
> does anyone know when it will be?
>
> regards
> p.s.
> i love bash completion :)
> the only thing i wouldn't want it to
> support is password completion :))


Basic rsync support is in there already. Just try 'rsync --<Tab>' and see what you get.

Thanks for your kind words.

09 Dec 2002 11:27 ianmacd

Re: ~/.bash_completion

> In the documentation for bash_completion
> it says that to add local completions
> they should go in ~/.bash_completion .
> What format should they be in?


They should be simple shell scripts. They will be sourced at the end of /etc/bash_completion, so they need not contain a shebang line nor be executable.

Screenshot

Project Spotlight

ReciJournal

An open, cross-platform journaling program.

Screenshot

Project Spotlight

Veusz

A scientific plotting package.