Generate shell completion scripts for iics.
Completion scripts enable tab-completion of commands, subcommands, and flags in your shell. They are generated dynamically from the installed binary, so they automatically reflect the commands and flags of the version you have installed.
iics completion <shell>| Subcommand | Description |
|---|---|
bash |
Generate bash completion script |
zsh |
Generate zsh completion script |
fish |
Generate fish completion script |
powershell |
Generate PowerShell completion script |
source <(iics completion bash)iics completion powershell | Out-String | Invoke-Expressioniics completion bash > /etc/bash_completion.d/iicsThen start a new shell or run source /etc/bash_completion.d/iics.
Requires bash-completion@2 (the macOS system bash does not support dynamic completion):
brew install bash-completion@2
iics completion bash > $(brew --prefix)/etc/bash_completion.d/iicsAdd to ~/.bash_profile if not already present:
[[ -r "$(brew --prefix)/etc/profile.d/bash_completion.sh" ]] && \
source "$(brew --prefix)/etc/profile.d/bash_completion.sh"source <(iics completion zsh)If shell completion is not already enabled, add this to ~/.zshrc:
autoload -U compinit; compinitThen install the completion file onto your fpath:
iics completion zsh > "${fpath[1]}/_iics"Start a new shell or reload:
source ~/.zshrciics completion zsh > ~/.oh-my-zsh/completions/_iicsiics completion fish | sourceiics completion fish > ~/.config/fish/completions/iics.fishCompletions are loaded automatically by fish on the next shell start.
iics completion powershell | Out-String | Invoke-ExpressionAppend to your PowerShell profile (creates the file if it does not exist):
iics completion powershell >> $PROFILEThe completions/ directory in the repository contains pre-generated scripts for all
supported shells. These are regenerated automatically when running make completions or
make all, and must be kept in sync with the command set.
| File | Shell |
|---|---|
completions/iics.bash |
bash |
completions/iics.zsh |
zsh |
completions/iics.fish |
fish |
completions/iics.ps1 |
PowerShell |
To regenerate after adding or changing commands:
make completions