Autocomplete
Talks about:
<a class="post-tag post-tag-autocomplete" href="/tags/autocomplete">autocomplete</a>
The ilo generate-completion
command generates autocompletion configuration for shells such as bash and zsh.
Once enabled you can use the <TAB>
key to autocomplete ilo commands and their options:
# autocomplete commands
$ ilo s<TAB>
$ ilo shell
# autocomplete options
$ ilo shell --re<TAB>
$ ilo shell --remove-image
bash
In order to integrate autocompletion into bash, follow these steps:
- Create or edit
~/.bashrc
. - Add the following line
source <(ilo generate-completion)
- Reload your shell (or create a new one)
zsh
In order to integrate autocompletion into zsh, follow these steps:
- Create or edit
$ZDOTDIR/.zshrc
. - Add the following line
source <(ilo generate-completion)
- Reload your shell (or create a new one)