-
Notifications
You must be signed in to change notification settings - Fork 27
Open
Labels
Description
Having CompletionCommand::execute
attempt completion by default is a pretty poor user experience, especially if you're not sure what the command is for since it gives an error immediately that references the library internals:
$ myapp _completion
[RuntimeException]
Failed to configure from environment; Environment var COMP_LINE not set.
_completion [-g|--generate-hook] [-p|--program="..."] [--shell-type[="..."]]
Ideally this would be changed so that:
- By default (ie. with no options or arguments), the running
myapp _completion
prints use instructions or help. - An option like
--run-completion
is required to attempt completion.
matt-allan