#compdef solo2

autoload -U is-at-least

_solo2() {
    typeset -A opt_args
    typeset -a _arguments_options
    local ret=1

    if is-at-least 5.2; then
        _arguments_options=(-s -S -C)
    else
        _arguments_options=(-s -C)
    fi

    local context curcontext="$curcontext" state line
    _arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'-h[Print help information]' \
'--help[Print help information]' \
'-V[Print version information]' \
'--version[Print version information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2_commands" \
"*::: :->solo2" \
&& ret=0
    case $state in
    (solo2)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-command-$line[1]:"
        case $line[1] in
            (app)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app_commands" \
"*::: :->app" \
&& ret=0

    case $state in
    (app)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-command-$line[1]:"
        case $line[1] in
            (admin)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__admin_commands" \
"*::: :->admin" \
&& ret=0

    case $state in
    (admin)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-admin-command-$line[1]:"
        case $line[1] in
            (aid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(reboot)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(boot-to-bootrom)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(uuid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(version)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(fido)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__fido_commands" \
"*::: :->fido" \
&& ret=0

    case $state in
    (fido)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-fido-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(wink)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(ndef)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__ndef_commands" \
"*::: :->ndef" \
&& ret=0

    case $state in
    (ndef)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-ndef-command-$line[1]:"
        case $line[1] in
            (aid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(capabilities)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(data)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(oath)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__oath_commands" \
"*::: :->oath" \
&& ret=0

    case $state in
    (oath)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-oath-command-$line[1]:"
        case $line[1] in
            (aid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(register)
_arguments "${_arguments_options[@]}" \
'-i+[(optional) issuer to use for the OATH credential, e.g., example.com]:ISSUER: ' \
'--issuer=[(optional) issuer to use for the OATH credential, e.g., example.com]:ISSUER: ' \
'-a+[]:ALGORITHM:(sha1 sha256)' \
'--algorithm=[]:ALGORITHM:(sha1 sha256)' \
'-k+[]:KIND:(hotp totp)' \
'--kind=[]:KIND:(hotp totp)' \
'-c+[(only HOTP) initial counter to use for HOTPs]:COUNTER: ' \
'--counter=[(only HOTP) initial counter to use for HOTPs]:COUNTER: ' \
'-d+[number of digits to output]:DIGITS:(6 7 8)' \
'--digits=[number of digits to output]:DIGITS:(6 7 8)' \
'-p+[(only TOTP) period in seconds for which a TOTP is valid]:PERIOD: ' \
'--period=[(only TOTP) period in seconds for which a TOTP is valid]:PERIOD: ' \
'--help[Print help information]' \
'--version[Print version information]' \
':label -- label to use for the OATH secret, e.g. alice@trussed.dev:' \
':secret -- the actual OATH seed, e.g. JBSWY3DPEHPK3PXPJBSWY3DPEHPK3PXP:' \
&& ret=0
;;
(delete)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':label -- Label of credential:' \
&& ret=0
;;
(list)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(reset)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(totp)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':label -- Label of credential:' \
'::timestamp -- timestamp to use to generate the OTP, as seconds since the UNIX epoch:' \
&& ret=0
;;
        esac
    ;;
esac
;;
(piv)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__piv_commands" \
"*::: :->piv" \
&& ret=0

    case $state in
    (piv)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-piv-command-$line[1]:"
        case $line[1] in
            (aid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(provision)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__provision_commands" \
"*::: :->provision" \
&& ret=0

    case $state in
    (provision)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-provision-command-$line[1]:"
        case $line[1] in
            (aid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(generate-ed255-key)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(generate-p256-key)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(generate-x255-key)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(store-ed255-cert)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':der -- Certificate in DER format:' \
&& ret=0
;;
(store-p256-cert)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':der -- Certificate in DER format:' \
&& ret=0
;;
(store-x255-cert)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':der -- Certificate in DER format:' \
&& ret=0
;;
(store-t1-pubkey)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':bytes -- Ed255 public key (raw, 32 bytes):' \
&& ret=0
;;
(store-fido-batch-cert)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':cert -- Attestation certificate:' \
&& ret=0
;;
(store-fido-batch-key)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':bytes -- P256 private key in internal format:' \
&& ret=0
;;
(reformat-filesystem)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
(write-file)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':data -- binary data file:' \
':path -- path in internal filesystem:' \
&& ret=0
;;
        esac
    ;;
esac
;;
(qa)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__app__qa_commands" \
"*::: :->qa" \
&& ret=0

    case $state in
    (qa)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-app-qa-command-$line[1]:"
        case $line[1] in
            (aid)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(help)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(pki)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__pki_commands" \
"*::: :->pki" \
&& ret=0

    case $state in
    (pki)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-pki-command-$line[1]:"
        case $line[1] in
            (ca)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__pki__ca_commands" \
"*::: :->ca" \
&& ret=0

    case $state in
    (ca)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-pki-ca-command-$line[1]:"
        case $line[1] in
            (fetch-certificate)
_arguments "${_arguments_options[@]}" \
'--help[Print help information]' \
'--version[Print version information]' \
':authority -- Name of authority, e.g. R1, T1, S3, etc:' \
&& ret=0
;;
        esac
    ;;
esac
;;
(help)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(bootloader)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
":: :_solo2__bootloader_commands" \
"*::: :->bootloader" \
&& ret=0

    case $state in
    (bootloader)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:solo2-bootloader-command-$line[1]:"
        case $line[1] in
            (reboot)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
(list)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--version[Print version information]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
        esac
    ;;
esac
;;
(list)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
(update)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'-y[DANGER! Proceed with major updates without prompt]' \
'--yes[DANGER! Proceed with major updates without prompt]' \
'-a[Update all connected SoloKeys Solo 2 devices]' \
'--all[Update all connected SoloKeys Solo 2 devices]' \
'-h[Print help information]' \
'--help[Print help information]' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
'::firmware -- Update to a specific firmware secure boot file (.sb2):' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" \
'-u+[Specify UUID of a Solo 2 device]:UUID: ' \
'--uuid=[Specify UUID of a Solo 2 device]:UUID: ' \
'--ctap[Prefer CTAP transport]' \
'--pcsc[Prefer PCSC transport]' \
&& ret=0
;;
        esac
    ;;
esac
}

(( $+functions[_solo2_commands] )) ||
_solo2_commands() {
    local commands; commands=(
'app:Interact with on-device applications' \
'pki:PKI-related' \
'bootloader:Interact with bootloader' \
'list:List all available devices' \
'ls:List all available devices' \
'update:Update to latest firmware published by SoloKeys. Warns on Major updates' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'solo2 commands' commands "$@"
}
(( $+functions[_solo2__app__admin_commands] )) ||
_solo2__app__admin_commands() {
    local commands; commands=(
'aid:Print the application'\''s AID' \
'reboot:Reboot device (as Solo 2)' \
'boot-to-bootrom:Reboot device (into Lpc 55 bootloader)' \
'uuid:Return device UUID (not available over CTAP in early firmware)' \
'version:Return device firmware version' \
    )
    _describe -t commands 'solo2 app admin commands' commands "$@"
}
(( $+functions[_solo2__app__admin__aid_commands] )) ||
_solo2__app__admin__aid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app admin aid commands' commands "$@"
}
(( $+functions[_solo2__app__ndef__aid_commands] )) ||
_solo2__app__ndef__aid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app ndef aid commands' commands "$@"
}
(( $+functions[_solo2__app__oath__aid_commands] )) ||
_solo2__app__oath__aid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app oath aid commands' commands "$@"
}
(( $+functions[_solo2__app__piv__aid_commands] )) ||
_solo2__app__piv__aid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app piv aid commands' commands "$@"
}
(( $+functions[_solo2__app__provision__aid_commands] )) ||
_solo2__app__provision__aid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision aid commands' commands "$@"
}
(( $+functions[_solo2__app__qa__aid_commands] )) ||
_solo2__app__qa__aid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app qa aid commands' commands "$@"
}
(( $+functions[_solo2__app_commands] )) ||
_solo2__app_commands() {
    local commands; commands=(
'admin:admin app' \
'fido:FIDO app' \
'ndef:NDEF app' \
'oath:OATH app' \
'piv:PIV app' \
'provision:Provision app' \
'qa:QA app' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'solo2 app commands' commands "$@"
}
(( $+functions[_solo2__app__admin__boot-to-bootrom_commands] )) ||
_solo2__app__admin__boot-to-bootrom_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app admin boot-to-bootrom commands' commands "$@"
}
(( $+functions[_solo2__bootloader_commands] )) ||
_solo2__bootloader_commands() {
    local commands; commands=(
'reboot:Reboots (into device if firmware is valid)' \
'list:List all available bootloaders' \
'ls:List all available bootloaders' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'solo2 bootloader commands' commands "$@"
}
(( $+functions[_solo2__pki__ca_commands] )) ||
_solo2__pki__ca_commands() {
    local commands; commands=(
'fetch-certificate:Fetch one of the well-known Solo 2 PKI certificates in DER format' \
    )
    _describe -t commands 'solo2 pki ca commands' commands "$@"
}
(( $+functions[_solo2__app__ndef__capabilities_commands] )) ||
_solo2__app__ndef__capabilities_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app ndef capabilities commands' commands "$@"
}
(( $+functions[_solo2__app__ndef__data_commands] )) ||
_solo2__app__ndef__data_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app ndef data commands' commands "$@"
}
(( $+functions[_solo2__app__oath__delete_commands] )) ||
_solo2__app__oath__delete_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app oath delete commands' commands "$@"
}
(( $+functions[_solo2__pki__ca__fetch-certificate_commands] )) ||
_solo2__pki__ca__fetch-certificate_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 pki ca fetch-certificate commands' commands "$@"
}
(( $+functions[_solo2__app__fido_commands] )) ||
_solo2__app__fido_commands() {
    local commands; commands=(
'init:FIDO init response' \
'wink:FIDO wink' \
    )
    _describe -t commands 'solo2 app fido commands' commands "$@"
}
(( $+functions[_solo2__app__provision__generate-ed255-key_commands] )) ||
_solo2__app__provision__generate-ed255-key_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision generate-ed255-key commands' commands "$@"
}
(( $+functions[_solo2__app__provision__generate-p256-key_commands] )) ||
_solo2__app__provision__generate-p256-key_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision generate-p256-key commands' commands "$@"
}
(( $+functions[_solo2__app__provision__generate-x255-key_commands] )) ||
_solo2__app__provision__generate-x255-key_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision generate-x255-key commands' commands "$@"
}
(( $+functions[_solo2__app__help_commands] )) ||
_solo2__app__help_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app help commands' commands "$@"
}
(( $+functions[_solo2__bootloader__help_commands] )) ||
_solo2__bootloader__help_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 bootloader help commands' commands "$@"
}
(( $+functions[_solo2__help_commands] )) ||
_solo2__help_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 help commands' commands "$@"
}
(( $+functions[_solo2__pki__help_commands] )) ||
_solo2__pki__help_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 pki help commands' commands "$@"
}
(( $+functions[_solo2__app__fido__init_commands] )) ||
_solo2__app__fido__init_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app fido init commands' commands "$@"
}
(( $+functions[_solo2__app__oath__list_commands] )) ||
_solo2__app__oath__list_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app oath list commands' commands "$@"
}
(( $+functions[_solo2__bootloader__list_commands] )) ||
_solo2__bootloader__list_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 bootloader list commands' commands "$@"
}
(( $+functions[_solo2__list_commands] )) ||
_solo2__list_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 list commands' commands "$@"
}
(( $+functions[_solo2__app__ndef_commands] )) ||
_solo2__app__ndef_commands() {
    local commands; commands=(
'aid:Print the application'\''s AID' \
'capabilities:NDEF capabilities' \
'data:NDEF data' \
    )
    _describe -t commands 'solo2 app ndef commands' commands "$@"
}
(( $+functions[_solo2__app__oath_commands] )) ||
_solo2__app__oath_commands() {
    local commands; commands=(
'aid:Print the application'\''s AID' \
'register:Register new credential' \
'delete:Delete existing credential' \
'list:List all credentials' \
'reset:Reset OATH app, deleting all credentials' \
'totp:Calculate TOTP for a registered credential' \
    )
    _describe -t commands 'solo2 app oath commands' commands "$@"
}
(( $+functions[_solo2__app__piv_commands] )) ||
_solo2__app__piv_commands() {
    local commands; commands=(
'aid:Print the application'\''s AID' \
    )
    _describe -t commands 'solo2 app piv commands' commands "$@"
}
(( $+functions[_solo2__pki_commands] )) ||
_solo2__pki_commands() {
    local commands; commands=(
'ca:CA-related' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'solo2 pki commands' commands "$@"
}
(( $+functions[_solo2__app__provision_commands] )) ||
_solo2__app__provision_commands() {
    local commands; commands=(
'aid:Print the application'\''s AID' \
'generate-ed255-key:Generate new Trussed Ed255 attestation key' \
'generate-p256-key:Generate new Trussed P256 attestation key' \
'generate-x255-key:Generate new Trussed X255 attestation key' \
'store-ed255-cert:Store Trussed Ed255 attestation certificate' \
'store-p256-cert:Store Trussed P256 attestation certificate' \
'store-x255-cert:Store Trussed X255 attestation certificate' \
'store-t1-pubkey:Store Trussed T1 intermediate public key' \
'store-fido-batch-cert:Store FIDO batch attestation certificate' \
'store-fido-batch-key:Store FIDO batch attestation private key' \
'reformat-filesystem:Reformat the internal filesystem' \
'write-file:Write binary file to specified path' \
    )
    _describe -t commands 'solo2 app provision commands' commands "$@"
}
(( $+functions[_solo2__app__qa_commands] )) ||
_solo2__app__qa_commands() {
    local commands; commands=(
'aid:Print the application'\''s AID' \
    )
    _describe -t commands 'solo2 app qa commands' commands "$@"
}
(( $+functions[_solo2__app__admin__reboot_commands] )) ||
_solo2__app__admin__reboot_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app admin reboot commands' commands "$@"
}
(( $+functions[_solo2__bootloader__reboot_commands] )) ||
_solo2__bootloader__reboot_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 bootloader reboot commands' commands "$@"
}
(( $+functions[_solo2__app__provision__reformat-filesystem_commands] )) ||
_solo2__app__provision__reformat-filesystem_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision reformat-filesystem commands' commands "$@"
}
(( $+functions[_solo2__app__oath__register_commands] )) ||
_solo2__app__oath__register_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app oath register commands' commands "$@"
}
(( $+functions[_solo2__app__oath__reset_commands] )) ||
_solo2__app__oath__reset_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app oath reset commands' commands "$@"
}
(( $+functions[_solo2__app__provision__store-ed255-cert_commands] )) ||
_solo2__app__provision__store-ed255-cert_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision store-ed255-cert commands' commands "$@"
}
(( $+functions[_solo2__app__provision__store-fido-batch-cert_commands] )) ||
_solo2__app__provision__store-fido-batch-cert_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision store-fido-batch-cert commands' commands "$@"
}
(( $+functions[_solo2__app__provision__store-fido-batch-key_commands] )) ||
_solo2__app__provision__store-fido-batch-key_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision store-fido-batch-key commands' commands "$@"
}
(( $+functions[_solo2__app__provision__store-p256-cert_commands] )) ||
_solo2__app__provision__store-p256-cert_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision store-p256-cert commands' commands "$@"
}
(( $+functions[_solo2__app__provision__store-t1-pubkey_commands] )) ||
_solo2__app__provision__store-t1-pubkey_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision store-t1-pubkey commands' commands "$@"
}
(( $+functions[_solo2__app__provision__store-x255-cert_commands] )) ||
_solo2__app__provision__store-x255-cert_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision store-x255-cert commands' commands "$@"
}
(( $+functions[_solo2__app__oath__totp_commands] )) ||
_solo2__app__oath__totp_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app oath totp commands' commands "$@"
}
(( $+functions[_solo2__update_commands] )) ||
_solo2__update_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 update commands' commands "$@"
}
(( $+functions[_solo2__app__admin__uuid_commands] )) ||
_solo2__app__admin__uuid_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app admin uuid commands' commands "$@"
}
(( $+functions[_solo2__app__admin__version_commands] )) ||
_solo2__app__admin__version_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app admin version commands' commands "$@"
}
(( $+functions[_solo2__app__fido__wink_commands] )) ||
_solo2__app__fido__wink_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app fido wink commands' commands "$@"
}
(( $+functions[_solo2__app__provision__write-file_commands] )) ||
_solo2__app__provision__write-file_commands() {
    local commands; commands=()
    _describe -t commands 'solo2 app provision write-file commands' commands "$@"
}

_solo2 "$@"