CmdID

CmdID / Commands

complete

Get and set argument autocompletion rules of shell commands in Bash. tldr-pages

On several platforms

Opens CmdID with your command. It is read in your browser and sent nowhere.

Several platforms

from tldr-pages, CC BY 4.0

Get and set argument autocompletion rules of shell commands in Bash. The specified completions will be invoked when <Tab> is pressed in Bash.

Set arguments of a command to autocomplete through a function (completion response is sent in $COMPREPLY variable)

complete -F function commandIdentify

Set arguments of a command to autocomplete through another command ($1 is the command, $2 is the argument the cursor is on, and $3 is the argument preceding the cursor)

complete -C autocomplete_command commandIdentify

Set arguments of a command to autocomplete to shell builtins

complete -b commandIdentify

Apply autocompletion without appending a space to the completed word

complete -o nospace -F function commandIdentify

List all loaded complete specifications

complete -pIdentify

List loaded complete specifications for a command

complete -p commandIdentify