[Bash-completion-devel] Non-completions

Raph gibboris at gmail.com
Tue Feb 8 10:49:31 UTC 2011


On Mon, Feb 07, 2011 at 10:52:12PM +0200, Ville Skyttä wrote:
> Just a thought I've had some time, not sure if it'd be a good idea or not:
> 
> What do people think about installing non-completions?  This would be
> for commands for which we know the bash default (file) completion is so
> bad that not completing at all would be better but we don't have a full
> completion for the command yet.
> 
> For example, for command "foo" that either does not take an argument or
> takes something entirely different than the file names bash would
> suggest for it by default:
> 
> $ _noop() { true; }
> $ complete -F _noop foo
> $ foo <TAB>
> (nothing)
> 
> This should however be combined with at least the redirection stuff
> discussed in another thread today so we won't break that.

As long as "Alt+/" is still usable :)
Maybe the bash users should take the habit of using two different
bindings depending of what they expect to be completed, filenames or
command arguments (<tab> or Alt+/) ?


Raph



More information about the Bash-completion-devel mailing list