function _commands()
{
  latest="${COMP_WORDS[$COMP_CWORD]}"
  prev="${COMP_WORDS[$COMP_CWORD - 1]}"
  words=""
  case "${prev}" in
    kroko-cli)
      words="get-gpus best-driver autoinstall help"
    ;;
  esac

  COMPREPLY=($(compgen -W "$words" -- $latest))
  return 0
}

complete -F _commands kroko-cli
