Skip to content
Snippets Groups Projects
user avatar
Jack Nagel authored
We make the assumption that the first non-option word is the command
being invoked.

Originally I was trying to allow command completion for non-standard
command lines like

    $ brew --verbose inst<TAB>

but right now executing something like that doesn't actually work. Which
is interesting, because the man page implies that it should. Either the
man page is incorrect, or something was broken between then and now.

Anyway, it would probably be safe to just assume that COMP_WORDS[1] is
the command, and we do make that assumption in other places. But if we
ever do allow things like "brew --option command", this will be useful.

Signed-off-by: default avatarJack Nagel <jacknagel@gmail.com>
e4bed29e
History
Name Last commit Last update
Library
bin
share/man/man1
.gitignore
README.md