Enable command completion

Completion allows you to hit [TAB] on a partially entered akkasls command and have the shell complete the command, subcommand or flag for you.


To load completion in the current bash shell run:

source <(akkasls completion)

Configure bash to load akkasls completions for each session by adding the following line to your ~/.bashrc or ~/.profile file:

# add to ~/.bashrc or ~/.profile
source <(akkasls completion)

Using bash completions with akkasls requires you have bash completions enabled to begin with. Enable it in your ~/.bashrc or ~/.profile file with the following lines:

if [ -f /etc/bash_completion ]; then
  source /etc/bash_completion

For definitive details on setting up your shell with auto-completion, see the shell documentation.

zsh (e.g. macOS)

To set up zsh shell completion run:

akkasls completion --shell zsh > "${fpath[1]}/_akkasls"

If shell completion is not already enabled in your environment execute the following:

echo "autoload -U compinit; compinit" >> ~/.zshrc

To set up fish shell completion run:

akkasls completion --shell fish > ~/.config/fish/completions/akkasls.fish
source ~/.config/fish/completions/akkasls.fish

To set up shell completion for PowerShell run:

akkasls completion --shell powershell | Out-String | Invoke-Expression