#compdef anchor

autoload -U is-at-least

_anchor() {
    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[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
'-V[Print version]' \
'--version[Print version]' \
":: :_anchor_commands" \
"*::: :->anchor-cli" \
&& ret=0
    case $state in
    (anchor-cli)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
'--package-manager=[Package Manager to use. If omitted, detection cascades \`pnpm\` -> \`yarn\` -> \`npm\` and picks the first one on PATH. When set explicitly, the chosen binary must be installed]:PACKAGE_MANAGER:((npm\:"Use npm as the package manager"
yarn\:"Use yarn as the package manager"
pnpm\:"Use pnpm as the package manager"
bun\:"Use bun as the package manager"))' \
'-t+[Rust program template to use]:TEMPLATE:((single\:"Program with a single \`lib.rs\` file (not recommended for production)"
multiple\:"Program with multiple files for instructions, state... (recommended)"))' \
'--template=[Rust program template to use]:TEMPLATE:((single\:"Program with a single \`lib.rs\` file (not recommended for production)"
multiple\:"Program with multiple files for instructions, state... (recommended)"))' \
'--anchor-version=[Anchor template version to generate]:ANCHOR_VERSION:((v1\:"Generate Anchor v1 templates"
v2\:"Generate Anchor v2 templates"))' \
'--test-template=[Test template to use]:TEST_TEMPLATE:((mocha\:"Generate template for Mocha unit-test"
jest\:"Generate template for Jest unit-test"
rust\:"Generate template for Rust unit-test"
mollusk\:"Generate template for Mollusk Rust unit-test"
litesvm\:"Generate template for LiteSVM rust unit-test"))' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-j[Use JavaScript instead of TypeScript]' \
'--javascript[Use JavaScript instead of TypeScript]' \
'--no-install[Don'\''t install JavaScript dependencies]' \
'--no-git[Don'\''t initialize git]' \
'--force[Initialize even if there are files]' \
'--install-agent-skills[Install Solana agent skills]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
':name -- Workspace name:_default' \
&& ret=0
;;
(build)
_arguments "${_arguments_options[@]}" : \
'-i+[Output directory for the IDL]:IDL:_default' \
'--idl=[Output directory for the IDL]:IDL:_default' \
'-t+[Output directory for the TypeScript IDL]:IDL_TS:_default' \
'--idl-ts=[Output directory for the TypeScript IDL]:IDL_TS:_default' \
'-p+[Name of the program to build]:PROGRAM_NAME:_default' \
'--program-name=[Name of the program to build]:PROGRAM_NAME:_default' \
'-s+[Version of the Solana toolchain to use. For --verifiable builds only]:SOLANA_VERSION:_default' \
'--solana-version=[Version of the Solana toolchain to use. For --verifiable builds only]:SOLANA_VERSION:_default' \
'-d+[Docker image to use. For --verifiable builds only]:DOCKER_IMAGE:_default' \
'--docker-image=[Docker image to use. For --verifiable builds only]:DOCKER_IMAGE:_default' \
'-b+[Bootstrap docker image from scratch, installing all requirements for verifiable builds. Only works for debian-based images]:BOOTSTRAP:(none debian)' \
'--bootstrap=[Bootstrap docker image from scratch, installing all requirements for verifiable builds. Only works for debian-based images]:BOOTSTRAP:(none debian)' \
'*-e+[Environment variables to pass into the docker container]:ENV:_default' \
'*--env=[Environment variables to pass into the docker container]:ENV:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--skip-lint[True if the build should not fail even if there are no "CHECK" comments]' \
'--ignore-keys[Skip checking for program ID mismatch between keypair and declare_id]' \
'--no-idl[Do not build the IDL]' \
'-v[True if the build artifact needs to be deterministic and verifiable]' \
'--verifiable[True if the build artifact needs to be deterministic and verifiable]' \
'--no-docs[Suppress doc strings in IDL output]' \
'-h[Print help]' \
'--help[Print help]' \
'*::cargo_args -- Arguments to pass to the underlying `cargo build-sbf` command:_default' \
&& ret=0
;;
(expand)
_arguments "${_arguments_options[@]}" : \
'-p+[Expand only this program]:PROGRAM_NAME:_default' \
'--program-name=[Expand only this program]:PROGRAM_NAME:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--stdout[Write to stdout]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
'*::cargo_args -- Arguments to pass to the underlying `cargo expand` command:_default' \
&& ret=0
;;
(verify)
_arguments "${_arguments_options[@]}" : \
'(--current-dir)--repo-url=[The URL of the repository to verify against. Conflicts with \`--current-dir\`]:REPO_URL:_default' \
'--commit-hash=[The commit hash to verify against. Requires \`--repo-url\`]:COMMIT_HASH:_default' \
'--program-name=[Name of the program to run the command on. Defaults to the package name]:PROGRAM_NAME:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--current-dir[Verify against the source code in the current directory. Conflicts with \`--repo-url\`]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id -- The program ID to verify:_default' \
'*::args -- Any additional arguments to pass to `solana-verify`:_default' \
&& ret=0
;;
(test)
_arguments "${_arguments_options[@]}" : \
'-p+[Build and test only this program]:PROGRAM_NAME:_default' \
'--program-name=[Build and test only this program]:PROGRAM_NAME:_default' \
'*--run=[Run the test suites under the specified path]:RUN:_default' \
'--script=[Name of the script to run from \[scripts\] section (defaults to "test")]:SCRIPT:_default' \
'--validator=[Validator type to use for local testing]:VALIDATOR:((surfpool\:"Use Surfpool validator (default)"
legacy\:"Use Solana test validator"))' \
'*-e+[Environment variables to pass into the docker container]:ENV:_default' \
'*--env=[Environment variables to pass into the docker container]:ENV:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--skip-deploy[Use this flag if you want to run tests against previously deployed programs]' \
'--skip-lint[True if the build should not fail even if there are no "CHECK" comments where normally required]' \
'--skip-local-validator[Flag to skip starting a local validator, if the configured cluster url is a localnet]' \
'--skip-build[Flag to skip building the program in the workspace, use this to save time when running test and the program code is not altered]' \
'--no-idl[Do not build the IDL]' \
'--detach[Flag to keep the local validator running after tests to be able to check the transactions]' \
'--profile[Profile each test\: record per-test SBF register traces and render flamegraph SVGs under target/anchor-v2-profile]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
'*::args:_default' \
&& ret=0
;;
(fuzz)
_arguments "${_arguments_options[@]}" : \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__fuzz_commands" \
"*::: :->fuzz" \
&& ret=0

    case $state in
    (fuzz)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-fuzz-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_name -- Program name:_default' \
&& ret=0
;;
(run)
_arguments "${_arguments_options[@]}" : \
'--binary-in=[Run a prebuilt harness binary directly]:BINARY_IN:_files' \
'--timeout=[Stop after N seconds]:TIMEOUT:_default' \
'-j+[Run N parallel fuzzer workers]:CORES:_default' \
'--cores=[Run N parallel fuzzer workers]:CORES:_default' \
'--corpus-in=[Load seed corpus from directory]:CORPUS_IN:_files' \
'--corpus-out=[Write corpus to directory]:CORPUS_OUT:_files' \
'--crashes-out=[Custom crash output directory]:CRASHES_OUT:_files' \
'--crashes-meta-out=[Custom directory for .meta.json files (default\: same as crashes_out)]:CRASHES_META_OUT:_files' \
'--replay=[Replay a single crash/input file]:REPLAY:_files' \
'--seed=[Random seed for reproducible fuzzing]:SEED:_default' \
'--max-actions=[Maximum number of actions per fuzzer iteration (default\: 8 stateless, 100 stateful)]:MAX_ACTIONS:_default' \
'--max-depth=[Maximum state depth (action chain length) in stateful mode (default\: 15)]:MAX_DEPTH:_default' \
'--pool-size=[State pool capacity in stateful mode (default\: 256000)]:POOL_SIZE:_default' \
'--program-so=[Path to alternative program .so binary]:PROGRAM_SO:_files' \
'--symbols=[Path to debug binary with DWARF symbols (for source-level coverage with --coverage)]:SYMBOLS:_files' \
'--mode=[Remote fuzzing operational mode (dry_run, explore, coverage, reproduce, corpus_merge)]:MODE:_default' \
'--lcov-out=[LCOV coverage output path]:LCOV_OUT:_files' \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--release[Build in release mode]' \
'--coverage[Enable coverage reporting (single-core only)]' \
'--dry-run[Validate setup without fuzzing]' \
'--stop-on-crash[Stop fuzzing on first crash]' \
'--no-tracing[Disable SVM register tracing for higher throughput (no coverage guidance)]' \
'--stateful[Stateful fuzzing\: single action per iteration with state pool]' \
'--stats[Show detailed performance stats (profiling, memory, pick/exec breakdown)]' \
'-h[Print help]' \
'--help[Print help]' \
':program_name -- Program name:_default' \
':test_name -- Test name (corresponds to a Cargo feature):_default' \
&& ret=0
;;
(list)
_arguments "${_arguments_options[@]}" : \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
'::program_name -- Program name (omit to list all):_default' \
&& ret=0
;;
(show)
_arguments "${_arguments_options[@]}" : \
'--crashes-dir=[Custom crashes directory to read from]:CRASHES_DIR:_files' \
'--crash-meta-dir=[Custom directory for .meta.json files (default\: same as crashes_dir)]:CRASH_META_DIR:_files' \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--replay[Actually replay the crash (requires compiled binary)]' \
'--regen[Batch-regenerate .meta.json for all crashes (requires --replay)]' \
'-h[Print help]' \
'--help[Print help]' \
':program_name -- Program name (use "." to auto-detect):_default' \
'::crash_file -- Crash file to inspect:_default' \
&& ret=0
;;
(tmin)
_arguments "${_arguments_options[@]}" : \
'--crash-meta-dir=[Custom directory for .meta.json files (default\: same as crashes directory)]:CRASH_META_DIR:_files' \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--all[Minimize all crashes for this test]' \
'--release[Build in release mode]' \
'-h[Print help]' \
'--help[Print help]' \
':program_name -- Program name:_default' \
':test_name -- Test name:_default' \
'::crash_file -- Crash file to minimize (filename only, not full path):_default' \
&& ret=0
;;
(cmin)
_arguments "${_arguments_options[@]}" : \
'--corpus-in=[Input corpus directory (flag alternative)]:CORPUS_IN:_files' \
'--corpus-out=[Output directory (default\: overwrite input)]:CORPUS_OUT:_files' \
'-C+[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--harness-dir=[Use this directory instead of ./fuzz/<program_name>/]:HARNESS_DIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--release[Build in release mode]' \
'-h[Print help]' \
'--help[Print help]' \
':program_name -- Program name:_default' \
':test_name -- Test name:_default' \
'::corpus_dir -- Input corpus directory (positional):_files' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__fuzz__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-fuzz-help-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(run)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(list)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(show)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(tmin)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(cmin)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(new)
_arguments "${_arguments_options[@]}" : \
'-t+[Rust program template to use]:TEMPLATE:((single\:"Program with a single \`lib.rs\` file (not recommended for production)"
multiple\:"Program with multiple files for instructions, state... (recommended)"))' \
'--template=[Rust program template to use]:TEMPLATE:((single\:"Program with a single \`lib.rs\` file (not recommended for production)"
multiple\:"Program with multiple files for instructions, state... (recommended)"))' \
'--anchor-version=[Anchor template version to generate]:ANCHOR_VERSION:((v1\:"Generate Anchor v1 templates"
v2\:"Generate Anchor v2 templates"))' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--force[Create new program even if there is already one]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
':name -- Program name:_default' \
&& ret=0
;;
(debugger)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--skip-run[Skip the build+test phase and open the TUI over existing traces]' \
'--skip-build[Skip \`cargo build-sbf\`]' \
'--skip-lint[Forwarded to the underlying \`anchor test\` invocation]' \
'--gdb[Drive tests over sbpf'\''s gdb-stub instead of reading dumped trace files]' \
'-h[Print help]' \
'--help[Print help]' \
'::test_name -- Filter captured traces to tests whose name contains this substring:_default' \
'*::cargo_args -- Arguments to pass to the underlying `cargo build-sbf` command:_default' \
&& ret=0
;;
(coverage)
_arguments "${_arguments_options[@]}" : \
'--output=[Output path for the LCOV file]:OUTPUT:_default' \
'--trace-dir=[Directory containing register trace files]:TRACE_DIR:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--skip-run[Skip the build+test phase and generate coverage from existing traces]' \
'--skip-build[Skip \`cargo build-sbf\`]' \
'-h[Print help]' \
'--help[Print help]' \
'*::cargo_args -- Arguments to pass to the underlying `cargo build-sbf` command:_default' \
&& ret=0
;;
(idl)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__idl_commands" \
"*::: :->idl" \
&& ret=0

    case $state in
    (idl)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-idl-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
'-f+[]:FILEPATH:_files' \
'--filepath=[]:FILEPATH:_files' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--non-canonical[Create non-canonical metadata account (third-party metadata)]' \
'-h[Print help]' \
'--help[Print help]' \
'::program_id -- Program id to initialize IDL for. If not provided, discovers program ID from IDL:_default' \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
'-f+[]:FILEPATH:_files' \
'--filepath=[]:FILEPATH:_files' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
'::program_id -- Program id to upgrade IDL for. If not provided, discovers program ID from IDL:_default' \
&& ret=0
;;
(build)
_arguments "${_arguments_options[@]}" : \
'-p+[]:PROGRAM_NAME:_default' \
'--program-name=[]:PROGRAM_NAME:_default' \
'-o+[Output file for the IDL (stdout if not specified)]:OUT:_default' \
'--out=[Output file for the IDL (stdout if not specified)]:OUT:_default' \
'-t+[Output file for the TypeScript IDL]:OUT_TS:_default' \
'--out-ts=[Output file for the TypeScript IDL]:OUT_TS:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--no-docs[Suppress doc strings in output]' \
'--skip-lint[Do not check for safety comments]' \
'-h[Print help]' \
'--help[Print help]' \
'*::cargo_args -- Arguments to pass to the underlying `cargo test` command:_default' \
&& ret=0
;;
(fetch)
_arguments "${_arguments_options[@]}" : \
'-o+[Output file for the IDL (stdout if not specified)]:OUT:_default' \
'--out=[Output file for the IDL (stdout if not specified)]:OUT:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--non-canonical[Fetch non-canonical metadata account (third-party metadata)]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id:_default' \
&& ret=0
;;
(fetch-historical)
_arguments "${_arguments_options[@]}" : \
'--authority=[Fetch authority-scoped PMP metadata account history for this authority]:AUTHORITY:_default' \
'(--before --after)--slot=[Fetch IDL at specific slot]:SLOT:_default' \
'--before=[Fetch IDL before this date (YYYY-MM-DD)]:BEFORE:_default' \
'--after=[Fetch IDL after this date (YYYY-MM-DD)]:AFTER:_default' \
'--out-dir=[Output directory for fetched versions (defaults to the current directory)]:OUT_DIR:_files' \
'--rpc-workers=[Max parallel RPC workers for transaction fetches]:RPC_WORKERS:_default' \
'--rpc-max-retries=[Max retry attempts per transaction on 429/timeout errors]:RPC_MAX_RETRIES:_default' \
'--rpc-retry-backoff-ms=[Base backoff in milliseconds between retries (doubled each attempt)]:RPC_RETRY_BACKOFF_MS:_default' \
'--max-signatures=[Hard cap on signatures fetched per history source]:MAX_SIGNATURES:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'(--rpc-workers)--no-parallel[Force sequential transaction fetches (equivalent to --rpc-workers 1)]' \
'--verbose[Print diagnostic progress messages]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
':program_id:_default' \
&& ret=0
;;
(convert)
_arguments "${_arguments_options[@]}" : \
'-o+[Output file for the IDL (stdout if not specified)]:OUT:_files' \
'--out=[Output file for the IDL (stdout if not specified)]:OUT:_files' \
'-p+[Program id to initialize IDL for. If not provided, discovers program ID from IDL]:PROGRAM_ID:_default' \
'--program-id=[Program id to initialize IDL for. If not provided, discovers program ID from IDL]:PROGRAM_ID:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--to-legacy[Convert a current-spec IDL back to the legacy (pre Anchor v0.30) format. Without this flag the converter runs in the default direction (legacy -> current)]' \
'-h[Print help]' \
'--help[Print help]' \
':path -- Path to the IDL file:_files' \
&& ret=0
;;
(type)
_arguments "${_arguments_options[@]}" : \
'-o+[Output file for the IDL (stdout if not specified)]:OUT:_files' \
'--out=[Output file for the IDL (stdout if not specified)]:OUT:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':path -- Path to the IDL file:_files' \
&& ret=0
;;
(close)
_arguments "${_arguments_options[@]}" : \
'--seed=[The seed used for the metadata account (default\: "idl")]:SEED:_default' \
'--priority-fee=[Priority fees in micro-lamports per compute unit]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_id -- The program ID:_default' \
&& ret=0
;;
(create-buffer)
_arguments "${_arguments_options[@]}" : \
'-f+[Path to the metadata file]:FILEPATH:_files' \
'--filepath=[Path to the metadata file]:FILEPATH:_files' \
'--priority-fee=[Priority fees in micro-lamports per compute unit]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(set-buffer-authority)
_arguments "${_arguments_options[@]}" : \
'-n+[The new authority]:NEW_AUTHORITY:_default' \
'--new-authority=[The new authority]:NEW_AUTHORITY:_default' \
'--priority-fee=[Priority fees in micro-lamports per compute unit]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':buffer -- The buffer account address:_default' \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
'-b+[The buffer account address]:BUFFER:_default' \
'--buffer=[The buffer account address]:BUFFER:_default' \
'--seed=[The seed to use for the metadata account (default\: "idl")]:SEED:_default' \
'--priority-fee=[Priority fees in micro-lamports per compute unit]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--close-buffer[Close the buffer after writing]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id -- The program ID:_default' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__idl__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-idl-help-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(build)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fetch)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fetch-historical)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(convert)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(type)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(close)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(create-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-buffer-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(clean)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(deploy)
_arguments "${_arguments_options[@]}" : \
'-p+[Only deploy this program]:PROGRAM_NAME:_default' \
'--program-name=[Only deploy this program]:PROGRAM_NAME:_default' \
'--program-keypair=[Keypair of the program (filepath) (requires program-name)]:PROGRAM_KEYPAIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-v[If true, deploy from path target/verifiable]' \
'--verifiable[If true, deploy from path target/verifiable]' \
'--no-idl[Don'\''t upload IDL during deployment (IDL is uploaded by default)]' \
'-h[Print help]' \
'--help[Print help]' \
'*::solana_args -- Arguments to pass to the underlying `solana program deploy` command:_default' \
&& ret=0
;;
(migrate)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
'-p+[The program to upgrade]:PROGRAM_ID:_default' \
'--program-id=[The program to upgrade]:PROGRAM_ID:_default' \
'--max-retries=[Max times to retry on failure]:MAX_RETRIES:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_filepath -- Filepath to the new program binary:_files' \
'*::solana_args -- Arguments to pass to the underlying `solana program deploy` command:_default' \
&& ret=0
;;
(airdrop)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':amount -- Amount of SOL to airdrop:_default' \
'::pubkey -- Recipient address (defaults to configured wallet):_default' \
&& ret=0
;;
(cluster)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__cluster_commands" \
"*::: :->cluster" \
&& ret=0

    case $state in
    (cluster)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-cluster-command-$line[1]:"
        case $line[1] in
            (list)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__cluster__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-cluster-help-command-$line[1]:"
        case $line[1] in
            (list)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(config)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__config_commands" \
"*::: :->config" \
&& ret=0

    case $state in
    (config)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-config-command-$line[1]:"
        case $line[1] in
            (get)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(set)
_arguments "${_arguments_options[@]}" : \
'-u+[Cluster to connect to (custom URL). Use -um, -ud, -ut, -ul for standard clusters]:URL:_default' \
'--url=[Cluster to connect to (custom URL). Use -um, -ud, -ut, -ul for standard clusters]:URL:_default' \
'-k+[Path to wallet keypair file to update the Anchor.toml file with]:KEYPAIR:_files' \
'--keypair=[Path to wallet keypair file to update the Anchor.toml file with]:KEYPAIR:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__config__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-config-help-command-$line[1]:"
        case $line[1] in
            (get)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(shell)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(run)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':script -- The name of the script to run:_default' \
'*::script_args -- Argument to pass to the underlying script:_default' \
&& ret=0
;;
(keys)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__keys_commands" \
"*::: :->keys" \
&& ret=0

    case $state in
    (keys)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-keys-command-$line[1]:"
        case $line[1] in
            (list)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(sync)
_arguments "${_arguments_options[@]}" : \
'-p+[Only sync the given program instead of all programs]:PROGRAM_NAME:_default' \
'--program-name=[Only sync the given program instead of all programs]:PROGRAM_NAME:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__keys__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-keys-help-command-$line[1]:"
        case $line[1] in
            (list)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(sync)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(localnet)
_arguments "${_arguments_options[@]}" : \
'--validator=[Validator type to use for local testing]:VALIDATOR:((surfpool\:"Use Surfpool validator (default)"
legacy\:"Use Solana test validator"))' \
'*-e+[Environment variables to pass into the docker container]:ENV:_default' \
'*--env=[Environment variables to pass into the docker container]:ENV:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--skip-build[Flag to skip building the program in the workspace, use this to save time when running test and the program code is not altered]' \
'--skip-deploy[Use this flag if you want to run tests against previously deployed programs]' \
'--skip-lint[True if the build should not fail even if there are no "CHECK" comments where normally required]' \
'--ignore-keys[Skip checking for program ID mismatch between keypair and declare_id]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
'*::cargo_args -- Arguments to pass to the underlying `cargo build-sbf` command:_default' \
&& ret=0
;;
(account)
_arguments "${_arguments_options[@]}" : \
'--idl=[Path of IDL to use (defaults to workspace IDL)]:IDL:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':account_type -- Account struct to deserialize (format\: <program_name>.<Account>):_default' \
':address -- Address of the account to deserialize:_default' \
&& ret=0
;;
(completions)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':shell:(bash elvish fish powershell zsh)' \
&& ret=0
;;
(address)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(balance)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--lamports[Display balance in lamports instead of SOL]' \
'-h[Print help]' \
'--help[Print help]' \
'::pubkey -- Account to check balance for (defaults to configured wallet):_default' \
&& ret=0
;;
(epoch)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(epoch-info)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(logs)
_arguments "${_arguments_options[@]}" : \
'*--address=[Addresses to filter logs by]:ADDRESS:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--include-votes[Include vote transactions when monitoring all transactions]' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(show-account)
_arguments "${_arguments_options[@]}" : \
'-o+[Write the account data to this file]:OUTPUT_FILE:_files' \
'--output-file=[Write the account data to this file]:OUTPUT_FILE:_files' \
'--output=[Return information in specified output format]:OUTPUT:(json json-compact)' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--lamports[Display balance in lamports instead of SOL]' \
'-h[Print help]' \
'--help[Print help]' \
':account_address -- Account address to show:_default' \
&& ret=0
;;
(keygen)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__keygen_commands" \
"*::: :->keygen" \
&& ret=0

    case $state in
    (keygen)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-keygen-command-$line[1]:"
        case $line[1] in
            (new)
_arguments "${_arguments_options[@]}" : \
'-o+[Path to generated keypair file]:OUTFILE:_files' \
'--outfile=[Path to generated keypair file]:OUTFILE:_files' \
'-w+[Number of words in the mnemonic phrase \[possible values\: 12, 15, 18, 21, 24\]]:WORD_COUNT:_default' \
'--word-count=[Number of words in the mnemonic phrase \[possible values\: 12, 15, 18, 21, 24\]]:WORD_COUNT:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-f[Overwrite the output file if it exists]' \
'--force[Overwrite the output file if it exists]' \
'--no-passphrase[Do not prompt for a passphrase]' \
'--silent[Do not display the generated pubkey]' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(pubkey)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
'::keypair -- Keypair filepath:_files' \
&& ret=0
;;
(recover)
_arguments "${_arguments_options[@]}" : \
'-o+[Path to recovered keypair file]:OUTFILE:_files' \
'--outfile=[Path to recovered keypair file]:OUTFILE:_files' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-f[Overwrite the output file if it exists]' \
'--force[Overwrite the output file if it exists]' \
'--skip-seed-phrase-validation[Skip seed phrase validation]' \
'--no-passphrase[Do not prompt for a passphrase]' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(verify)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':pubkey -- Public key to verify:_default' \
'::keypair -- Keypair filepath (defaults to configured wallet):_files' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__keygen__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-keygen-help-command-$line[1]:"
        case $line[1] in
            (new)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(pubkey)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(recover)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(verify)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(program)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__program_commands" \
"*::: :->program" \
&& ret=0

    case $state in
    (program)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-program-command-$line[1]:"
        case $line[1] in
            (deploy)
_arguments "${_arguments_options[@]}" : \
'-p+[Program name to deploy (from workspace). Used when program_filepath is not provided]:PROGRAM_NAME:_default' \
'--program-name=[Program name to deploy (from workspace). Used when program_filepath is not provided]:PROGRAM_NAME:_default' \
'--program-keypair=[Program keypair filepath (defaults to target/deploy/{program_name}-keypair.json)]:PROGRAM_KEYPAIR:_files' \
'--upgrade-authority=[Upgrade authority keypair (defaults to configured wallet)]:UPGRADE_AUTHORITY:_default' \
'--program-id=[Program id to deploy to (derived from program-keypair if not specified)]:PROGRAM_ID:_default' \
'--buffer=[Buffer account to use for deployment]:BUFFER:_default' \
'--max-len=[Maximum transaction length (BPF loader upgradeable limit)]:MAX_LEN:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--use-rpc[Send write transactions through RPC instead of TPU]' \
'--no-idl[Don'\''t upload IDL during deployment (IDL is uploaded by default)]' \
'--final[Make the program immutable after deployment (cannot be upgraded)]' \
'-h[Print help]' \
'--help[Print help]' \
'::program_filepath -- Program filepath (e.g., target/deploy/my_program.so). If not provided, discovers programs from workspace:_files' \
'*::solana_args -- Additional arguments to configure deployment (e.g., --with-compute-unit-price 1000):_default' \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
'-p+[Program name to write (from workspace). Used when program_filepath is not provided]:PROGRAM_NAME:_default' \
'--program-name=[Program name to write (from workspace). Used when program_filepath is not provided]:PROGRAM_NAME:_default' \
'--buffer=[Buffer account keypair (defaults to new keypair)]:BUFFER:_default' \
'--buffer-authority=[Buffer authority (defaults to configured wallet)]:BUFFER_AUTHORITY:_default' \
'--max-len=[Maximum transaction length]:MAX_LEN:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
'::program_filepath -- Program filepath (e.g., target/deploy/my_program.so). If not provided, discovers program from workspace using program_name:_files' \
&& ret=0
;;
(set-buffer-authority)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':buffer -- Buffer account address:_default' \
':new_buffer_authority -- New buffer authority:_default' \
&& ret=0
;;
(set-upgrade-authority)
_arguments "${_arguments_options[@]}" : \
'--new-upgrade-authority=[New upgrade authority pubkey]:NEW_UPGRADE_AUTHORITY:_default' \
'--new-upgrade-authority-signer=[New upgrade authority signer (keypair file). Required unless --skip-new-upgrade-authority-signer-check is used. When provided, both current and new authority will sign (checked mode, recommended)]:NEW_UPGRADE_AUTHORITY_SIGNER:_default' \
'--upgrade-authority=[Current upgrade authority keypair (defaults to configured wallet)]:UPGRADE_AUTHORITY:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--skip-new-upgrade-authority-signer-check[Skip new upgrade authority signer check. Allows setting authority with only current authority signature. WARNING\: Less safe - use only if you'\''re confident the pubkey is correct]' \
'--final[Make the program immutable (cannot be upgraded)]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id -- Program id:_default' \
&& ret=0
;;
(show)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--get-programs[Get account information from the Solana config file]' \
'--get-buffers[Get account information from the Solana config file]' \
'--all[Show all accounts]' \
'-h[Print help]' \
'--help[Print help]' \
':account -- Account address (buffer or program):_default' \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
'--program-filepath=[Program filepath (e.g., target/deploy/my_program.so). If not provided, discovers from workspace]:PROGRAM_FILEPATH:_files' \
'-p+[Program name to upgrade (from workspace). Used when program_filepath is not provided]:PROGRAM_NAME:_default' \
'--program-name=[Program name to upgrade (from workspace). Used when program_filepath is not provided]:PROGRAM_NAME:_default' \
'--buffer=[Existing buffer account to upgrade from. If not provided, auto-discovers program from workspace]:BUFFER:_default' \
'--upgrade-authority=[Upgrade authority (defaults to configured wallet)]:UPGRADE_AUTHORITY:_default' \
'--max-retries=[Max times to retry on failure]:MAX_RETRIES:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--use-rpc[Send write transactions through RPC instead of TPU]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id -- Program id to upgrade:_default' \
'*::solana_args -- Additional arguments to configure deployment (e.g., --with-compute-unit-price 1000):_default' \
&& ret=0
;;
(dump)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':account -- Program account address:_default' \
':output_file -- Output file path:_default' \
&& ret=0
;;
(close)
_arguments "${_arguments_options[@]}" : \
'-p+[Program name to close (from workspace). Used when account is not provided]:PROGRAM_NAME:_default' \
'--program-name=[Program name to close (from workspace). Used when account is not provided]:PROGRAM_NAME:_default' \
'--authority=[Authority keypair (defaults to configured wallet)]:AUTHORITY:_default' \
'--recipient=[Recipient address for reclaimed lamports (defaults to authority)]:RECIPIENT:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--bypass-warning[Bypass warning prompts]' \
'-h[Print help]' \
'--help[Print help]' \
'::account -- Account address to close (buffer or program). If not provided, discovers program from workspace using program_name:_default' \
&& ret=0
;;
(extend)
_arguments "${_arguments_options[@]}" : \
'-p+[Program name to extend (from workspace). Used when program_id is not provided]:PROGRAM_NAME:_default' \
'--program-name=[Program name to extend (from workspace). Used when program_id is not provided]:PROGRAM_NAME:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
'::program_id -- Program id to extend. If not provided, discovers program from workspace using program_name:_default' \
':additional_bytes -- Additional bytes to allocate:_default' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__program__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-program-help-command-$line[1]:"
        case $line[1] in
            (deploy)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-buffer-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-upgrade-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(show)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(dump)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(close)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(extend)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(codama)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__codama_commands" \
"*::: :->codama" \
&& ret=0

    case $state in
    (codama)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-codama-command-$line[1]:"
        case $line[1] in
            (convert)
_arguments "${_arguments_options[@]}" : \
'-o+[Output file (stdout if not specified)]:OUT:_default' \
'--out=[Output file (stdout if not specified)]:OUT:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':path -- Path to the Anchor IDL JSON file:_default' \
&& ret=0
;;
(generate)
_arguments "${_arguments_options[@]}" : \
'*-l+[Languages to generate clients for. Repeat the flag or comma- separate values\: \`-l js,go -l rust\`]:LANGUAGE:(js js-umi rust go)' \
'*--language=[Languages to generate clients for. Repeat the flag or comma- separate values\: \`-l js,go -l rust\`]:LANGUAGE:(js js-umi rust go)' \
'-p+[Base output directory; per-language clients are written to \`<path>/<language>\`]:PATH:_default' \
'--path=[Base output directory; per-language clients are written to \`<path>/<language>\`]:PATH:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
':idl -- Path to the Anchor IDL JSON file:_default' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__codama__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-codama-help-command-$line[1]:"
        case $line[1] in
            (convert)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(generate)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(legacy-idl)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
":: :_anchor__subcmd__legacy-idl_commands" \
"*::: :->legacy-idl" \
&& ret=0

    case $state in
    (legacy-idl)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-legacy-idl-command-$line[1]:"
        case $line[1] in
            (close)
_arguments "${_arguments_options[@]}" : \
'--idl-address=[The IDL account to close. If none is given, the IDL account derived from program_id is used]:IDL_ADDRESS:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--print-only[Print the instruction in base64 without executing it. Useful for multisig execution when the local wallet keypair is not available]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id:_default' \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
'-f+[]:FILEPATH:_default' \
'--filepath=[]:FILEPATH:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_id:_default' \
&& ret=0
;;
(set-buffer)
_arguments "${_arguments_options[@]}" : \
'-b+[Address of the buffer account to set as the IDL on the program]:BUFFER:_default' \
'--buffer=[Address of the buffer account to set as the IDL on the program]:BUFFER:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--print-only[Print the instruction in base64 without executing it]' \
'-h[Print help]' \
'--help[Print help]' \
':program_id:_default' \
&& ret=0
;;
(set-authority)
_arguments "${_arguments_options[@]}" : \
'-p+[Program to change the IDL authority]:PROGRAM_ID:_default' \
'--program-id=[Program to change the IDL authority]:PROGRAM_ID:_default' \
'-n+[New authority of the IDL account]:NEW_AUTHORITY:_default' \
'--new-authority=[New authority of the IDL account]:NEW_AUTHORITY:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'--print-only[Print the instruction in base64 without executing it]' \
'-h[Print help]' \
'--help[Print help]' \
'::address -- The IDL account buffer to set the authority of. If none is given, the canonical IDL account is used:_default' \
&& ret=0
;;
(erase-authority)
_arguments "${_arguments_options[@]}" : \
'-p+[]:PROGRAM_ID:_default' \
'--program-id=[]:PROGRAM_ID:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
&& ret=0
;;
(authority)
_arguments "${_arguments_options[@]}" : \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_id -- The program to view:_default' \
&& ret=0
;;
(init)
_arguments "${_arguments_options[@]}" : \
'-f+[]:FILEPATH:_default' \
'--filepath=[]:FILEPATH:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_id:_default' \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
'-f+[]:FILEPATH:_default' \
'--filepath=[]:FILEPATH:_default' \
'--priority-fee=[]:PRIORITY_FEE:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':program_id:_default' \
&& ret=0
;;
(fetch)
_arguments "${_arguments_options[@]}" : \
'-o+[Path to write the fetched IDL. Prints to stdout if omitted]:OUT:_default' \
'--out=[Path to write the fetched IDL. Prints to stdout if omitted]:OUT:_default' \
'--provider.cluster=[Cluster override]:CLUSTER:_default' \
'--provider.wallet=[Wallet override]:WALLET:_default' \
'--commitment=[Commitment override (valid values\: processed, confirmed, finalized)]:COMMITMENT:_default' \
'-h[Print help]' \
'--help[Print help]' \
':address:_default' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__legacy-idl__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-legacy-idl-help-command-$line[1]:"
        case $line[1] in
            (close)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(erase-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fetch)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(build)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(expand)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(verify)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(test)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fuzz)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__fuzz_commands" \
"*::: :->fuzz" \
&& ret=0

    case $state in
    (fuzz)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-fuzz-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(run)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(list)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(show)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(tmin)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(cmin)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(new)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(debugger)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(coverage)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(idl)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__idl_commands" \
"*::: :->idl" \
&& ret=0

    case $state in
    (idl)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-idl-command-$line[1]:"
        case $line[1] in
            (init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(build)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fetch)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fetch-historical)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(convert)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(type)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(close)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(create-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-buffer-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(clean)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(deploy)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(migrate)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(airdrop)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(cluster)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__cluster_commands" \
"*::: :->cluster" \
&& ret=0

    case $state in
    (cluster)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-cluster-command-$line[1]:"
        case $line[1] in
            (list)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(config)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__config_commands" \
"*::: :->config" \
&& ret=0

    case $state in
    (config)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-config-command-$line[1]:"
        case $line[1] in
            (get)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(shell)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(run)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(keys)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__keys_commands" \
"*::: :->keys" \
&& ret=0

    case $state in
    (keys)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-keys-command-$line[1]:"
        case $line[1] in
            (list)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(sync)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(localnet)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(account)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(completions)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(address)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(balance)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(epoch)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(epoch-info)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(logs)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(show-account)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(keygen)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__keygen_commands" \
"*::: :->keygen" \
&& ret=0

    case $state in
    (keygen)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-keygen-command-$line[1]:"
        case $line[1] in
            (new)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(pubkey)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(recover)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(verify)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(program)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__program_commands" \
"*::: :->program" \
&& ret=0

    case $state in
    (program)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-program-command-$line[1]:"
        case $line[1] in
            (deploy)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-buffer-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-upgrade-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(show)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(dump)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(close)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(extend)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(codama)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__codama_commands" \
"*::: :->codama" \
&& ret=0

    case $state in
    (codama)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-codama-command-$line[1]:"
        case $line[1] in
            (convert)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(generate)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(legacy-idl)
_arguments "${_arguments_options[@]}" : \
":: :_anchor__subcmd__help__subcmd__legacy-idl_commands" \
"*::: :->legacy-idl" \
&& ret=0

    case $state in
    (legacy-idl)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:anchor-help-legacy-idl-command-$line[1]:"
        case $line[1] in
            (close)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(write-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-buffer)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(set-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(erase-authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(authority)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(init)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(upgrade)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(fetch)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
}

(( $+functions[_anchor_commands] )) ||
_anchor_commands() {
    local commands; commands=(
'init:Initializes a workspace' \
'build:Builds the workspace' \
'expand:Expands macros (wrapper around cargo expand)' \
'verify:Verifies the on-chain bytecode matches the locally compiled artifact. Run this command inside a program subdirectory, i.e., in the dir containing the program'\''s Cargo.toml' \
'test:Runs integration tests' \
'fuzz:Coverage-guided fuzzing for Solana programs (powered by Crucible)' \
'new:Creates a new program' \
'debugger:Run tests under an instruction-level debugger' \
'coverage:Generate source-level coverage from SBF register traces' \
'idl:Commands for interacting with interface definitions' \
'clean:Remove all artifacts from the generated directories except program keypairs' \
'deploy:Deploys each program in the workspace' \
'migrate:Runs the deploy migration script' \
'upgrade:Deploys, initializes an IDL, and migrates all in one command. Upgrades a single program. The configured wallet must be the upgrade authority' \
'airdrop:Request an airdrop of SOL' \
'cluster:Cluster commands' \
'config:Configuration management commands' \
'shell:Starts a node shell with an Anchor client setup according to the local config' \
'run:Runs the script defined by the current workspace'\''s Anchor.toml' \
'keys:Program keypair commands' \
'localnet:Localnet commands' \
'account:Fetch and deserialize an account using the IDL provided' \
'completions:Generates shell completions' \
'address:Get your public key' \
'balance:Get your balance' \
'epoch:Get current epoch' \
'epoch-info:Get information about the current epoch' \
'logs:Stream transaction logs' \
'show-account:Show the contents of an account' \
'keygen:Keypair generation and management' \
'program:Program deployment and management commands' \
'codama:Codama IDL integration commands' \
'legacy-idl:\[DEPRECATED\] Manage legacy on-chain IDL accounts. These commands interact with the old Anchor IDL instruction protocol and will be removed in a future release. Migrate to Program Metadata-based IDL management (\`anchor idl\`)' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor commands' commands "$@"
}
(( $+functions[_anchor__subcmd__account_commands] )) ||
_anchor__subcmd__account_commands() {
    local commands; commands=()
    _describe -t commands 'anchor account commands' commands "$@"
}
(( $+functions[_anchor__subcmd__address_commands] )) ||
_anchor__subcmd__address_commands() {
    local commands; commands=()
    _describe -t commands 'anchor address commands' commands "$@"
}
(( $+functions[_anchor__subcmd__airdrop_commands] )) ||
_anchor__subcmd__airdrop_commands() {
    local commands; commands=()
    _describe -t commands 'anchor airdrop commands' commands "$@"
}
(( $+functions[_anchor__subcmd__balance_commands] )) ||
_anchor__subcmd__balance_commands() {
    local commands; commands=()
    _describe -t commands 'anchor balance commands' commands "$@"
}
(( $+functions[_anchor__subcmd__build_commands] )) ||
_anchor__subcmd__build_commands() {
    local commands; commands=()
    _describe -t commands 'anchor build commands' commands "$@"
}
(( $+functions[_anchor__subcmd__clean_commands] )) ||
_anchor__subcmd__clean_commands() {
    local commands; commands=()
    _describe -t commands 'anchor clean commands' commands "$@"
}
(( $+functions[_anchor__subcmd__cluster_commands] )) ||
_anchor__subcmd__cluster_commands() {
    local commands; commands=(
'list:Prints common cluster urls' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor cluster commands' commands "$@"
}
(( $+functions[_anchor__subcmd__cluster__subcmd__help_commands] )) ||
_anchor__subcmd__cluster__subcmd__help_commands() {
    local commands; commands=(
'list:Prints common cluster urls' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor cluster help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__cluster__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__cluster__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor cluster help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__cluster__subcmd__help__subcmd__list_commands] )) ||
_anchor__subcmd__cluster__subcmd__help__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor cluster help list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__cluster__subcmd__list_commands] )) ||
_anchor__subcmd__cluster__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor cluster list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama_commands] )) ||
_anchor__subcmd__codama_commands() {
    local commands; commands=(
'convert:Convert an Anchor IDL JSON file (post-0.30 spec) into a Codama IDL rooted at a \`rootNode\`' \
'generate:Convert an Anchor IDL and run Codama renderers to produce client libraries in one or more languages' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor codama commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama__subcmd__convert_commands] )) ||
_anchor__subcmd__codama__subcmd__convert_commands() {
    local commands; commands=()
    _describe -t commands 'anchor codama convert commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama__subcmd__generate_commands] )) ||
_anchor__subcmd__codama__subcmd__generate_commands() {
    local commands; commands=()
    _describe -t commands 'anchor codama generate commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama__subcmd__help_commands] )) ||
_anchor__subcmd__codama__subcmd__help_commands() {
    local commands; commands=(
'convert:Convert an Anchor IDL JSON file (post-0.30 spec) into a Codama IDL rooted at a \`rootNode\`' \
'generate:Convert an Anchor IDL and run Codama renderers to produce client libraries in one or more languages' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor codama help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama__subcmd__help__subcmd__convert_commands] )) ||
_anchor__subcmd__codama__subcmd__help__subcmd__convert_commands() {
    local commands; commands=()
    _describe -t commands 'anchor codama help convert commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama__subcmd__help__subcmd__generate_commands] )) ||
_anchor__subcmd__codama__subcmd__help__subcmd__generate_commands() {
    local commands; commands=()
    _describe -t commands 'anchor codama help generate commands' commands "$@"
}
(( $+functions[_anchor__subcmd__codama__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__codama__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor codama help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__completions_commands] )) ||
_anchor__subcmd__completions_commands() {
    local commands; commands=()
    _describe -t commands 'anchor completions commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config_commands] )) ||
_anchor__subcmd__config_commands() {
    local commands; commands=(
'get:Get configuration settings from the local Anchor.toml' \
'set:Set configuration settings in the local Anchor.toml' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor config commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config__subcmd__get_commands] )) ||
_anchor__subcmd__config__subcmd__get_commands() {
    local commands; commands=()
    _describe -t commands 'anchor config get commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config__subcmd__help_commands] )) ||
_anchor__subcmd__config__subcmd__help_commands() {
    local commands; commands=(
'get:Get configuration settings from the local Anchor.toml' \
'set:Set configuration settings in the local Anchor.toml' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor config help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config__subcmd__help__subcmd__get_commands] )) ||
_anchor__subcmd__config__subcmd__help__subcmd__get_commands() {
    local commands; commands=()
    _describe -t commands 'anchor config help get commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__config__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor config help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config__subcmd__help__subcmd__set_commands] )) ||
_anchor__subcmd__config__subcmd__help__subcmd__set_commands() {
    local commands; commands=()
    _describe -t commands 'anchor config help set commands' commands "$@"
}
(( $+functions[_anchor__subcmd__config__subcmd__set_commands] )) ||
_anchor__subcmd__config__subcmd__set_commands() {
    local commands; commands=()
    _describe -t commands 'anchor config set commands' commands "$@"
}
(( $+functions[_anchor__subcmd__coverage_commands] )) ||
_anchor__subcmd__coverage_commands() {
    local commands; commands=()
    _describe -t commands 'anchor coverage commands' commands "$@"
}
(( $+functions[_anchor__subcmd__debugger_commands] )) ||
_anchor__subcmd__debugger_commands() {
    local commands; commands=()
    _describe -t commands 'anchor debugger commands' commands "$@"
}
(( $+functions[_anchor__subcmd__deploy_commands] )) ||
_anchor__subcmd__deploy_commands() {
    local commands; commands=()
    _describe -t commands 'anchor deploy commands' commands "$@"
}
(( $+functions[_anchor__subcmd__epoch_commands] )) ||
_anchor__subcmd__epoch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor epoch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__epoch-info_commands] )) ||
_anchor__subcmd__epoch-info_commands() {
    local commands; commands=()
    _describe -t commands 'anchor epoch-info commands' commands "$@"
}
(( $+functions[_anchor__subcmd__expand_commands] )) ||
_anchor__subcmd__expand_commands() {
    local commands; commands=()
    _describe -t commands 'anchor expand commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz_commands] )) ||
_anchor__subcmd__fuzz_commands() {
    local commands; commands=(
'init:Create a new fuzz harness for a program' \
'run:Run a fuzz test' \
'list:List available fuzz tests' \
'show:View/replay crashes' \
'tmin:Minimize a crash to smallest reproducing action sequence' \
'cmin:Minimize corpus to smallest set preserving coverage' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor fuzz commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__cmin_commands] )) ||
_anchor__subcmd__fuzz__subcmd__cmin_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz cmin commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help_commands() {
    local commands; commands=(
'init:Create a new fuzz harness for a program' \
'run:Run a fuzz test' \
'list:List available fuzz tests' \
'show:View/replay crashes' \
'tmin:Minimize a crash to smallest reproducing action sequence' \
'cmin:Minimize corpus to smallest set preserving coverage' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor fuzz help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__cmin_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__cmin_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help cmin commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__init_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__list_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__run_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__run_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help run commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__show_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__show_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help show commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__help__subcmd__tmin_commands] )) ||
_anchor__subcmd__fuzz__subcmd__help__subcmd__tmin_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz help tmin commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__init_commands] )) ||
_anchor__subcmd__fuzz__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__list_commands] )) ||
_anchor__subcmd__fuzz__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__run_commands] )) ||
_anchor__subcmd__fuzz__subcmd__run_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz run commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__show_commands] )) ||
_anchor__subcmd__fuzz__subcmd__show_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz show commands' commands "$@"
}
(( $+functions[_anchor__subcmd__fuzz__subcmd__tmin_commands] )) ||
_anchor__subcmd__fuzz__subcmd__tmin_commands() {
    local commands; commands=()
    _describe -t commands 'anchor fuzz tmin commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help_commands] )) ||
_anchor__subcmd__help_commands() {
    local commands; commands=(
'init:Initializes a workspace' \
'build:Builds the workspace' \
'expand:Expands macros (wrapper around cargo expand)' \
'verify:Verifies the on-chain bytecode matches the locally compiled artifact. Run this command inside a program subdirectory, i.e., in the dir containing the program'\''s Cargo.toml' \
'test:Runs integration tests' \
'fuzz:Coverage-guided fuzzing for Solana programs (powered by Crucible)' \
'new:Creates a new program' \
'debugger:Run tests under an instruction-level debugger' \
'coverage:Generate source-level coverage from SBF register traces' \
'idl:Commands for interacting with interface definitions' \
'clean:Remove all artifacts from the generated directories except program keypairs' \
'deploy:Deploys each program in the workspace' \
'migrate:Runs the deploy migration script' \
'upgrade:Deploys, initializes an IDL, and migrates all in one command. Upgrades a single program. The configured wallet must be the upgrade authority' \
'airdrop:Request an airdrop of SOL' \
'cluster:Cluster commands' \
'config:Configuration management commands' \
'shell:Starts a node shell with an Anchor client setup according to the local config' \
'run:Runs the script defined by the current workspace'\''s Anchor.toml' \
'keys:Program keypair commands' \
'localnet:Localnet commands' \
'account:Fetch and deserialize an account using the IDL provided' \
'completions:Generates shell completions' \
'address:Get your public key' \
'balance:Get your balance' \
'epoch:Get current epoch' \
'epoch-info:Get information about the current epoch' \
'logs:Stream transaction logs' \
'show-account:Show the contents of an account' \
'keygen:Keypair generation and management' \
'program:Program deployment and management commands' \
'codama:Codama IDL integration commands' \
'legacy-idl:\[DEPRECATED\] Manage legacy on-chain IDL accounts. These commands interact with the old Anchor IDL instruction protocol and will be removed in a future release. Migrate to Program Metadata-based IDL management (\`anchor idl\`)' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__account_commands] )) ||
_anchor__subcmd__help__subcmd__account_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help account commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__address_commands] )) ||
_anchor__subcmd__help__subcmd__address_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help address commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__airdrop_commands] )) ||
_anchor__subcmd__help__subcmd__airdrop_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help airdrop commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__balance_commands] )) ||
_anchor__subcmd__help__subcmd__balance_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help balance commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__build_commands] )) ||
_anchor__subcmd__help__subcmd__build_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help build commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__clean_commands] )) ||
_anchor__subcmd__help__subcmd__clean_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help clean commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__cluster_commands] )) ||
_anchor__subcmd__help__subcmd__cluster_commands() {
    local commands; commands=(
'list:Prints common cluster urls' \
    )
    _describe -t commands 'anchor help cluster commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__cluster__subcmd__list_commands] )) ||
_anchor__subcmd__help__subcmd__cluster__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help cluster list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__codama_commands] )) ||
_anchor__subcmd__help__subcmd__codama_commands() {
    local commands; commands=(
'convert:Convert an Anchor IDL JSON file (post-0.30 spec) into a Codama IDL rooted at a \`rootNode\`' \
'generate:Convert an Anchor IDL and run Codama renderers to produce client libraries in one or more languages' \
    )
    _describe -t commands 'anchor help codama commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__codama__subcmd__convert_commands] )) ||
_anchor__subcmd__help__subcmd__codama__subcmd__convert_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help codama convert commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__codama__subcmd__generate_commands] )) ||
_anchor__subcmd__help__subcmd__codama__subcmd__generate_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help codama generate commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__completions_commands] )) ||
_anchor__subcmd__help__subcmd__completions_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help completions commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__config_commands] )) ||
_anchor__subcmd__help__subcmd__config_commands() {
    local commands; commands=(
'get:Get configuration settings from the local Anchor.toml' \
'set:Set configuration settings in the local Anchor.toml' \
    )
    _describe -t commands 'anchor help config commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__config__subcmd__get_commands] )) ||
_anchor__subcmd__help__subcmd__config__subcmd__get_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help config get commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__config__subcmd__set_commands] )) ||
_anchor__subcmd__help__subcmd__config__subcmd__set_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help config set commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__coverage_commands] )) ||
_anchor__subcmd__help__subcmd__coverage_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help coverage commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__debugger_commands] )) ||
_anchor__subcmd__help__subcmd__debugger_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help debugger commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__deploy_commands] )) ||
_anchor__subcmd__help__subcmd__deploy_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help deploy commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__epoch_commands] )) ||
_anchor__subcmd__help__subcmd__epoch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help epoch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__epoch-info_commands] )) ||
_anchor__subcmd__help__subcmd__epoch-info_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help epoch-info commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__expand_commands] )) ||
_anchor__subcmd__help__subcmd__expand_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help expand commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz_commands() {
    local commands; commands=(
'init:Create a new fuzz harness for a program' \
'run:Run a fuzz test' \
'list:List available fuzz tests' \
'show:View/replay crashes' \
'tmin:Minimize a crash to smallest reproducing action sequence' \
'cmin:Minimize corpus to smallest set preserving coverage' \
    )
    _describe -t commands 'anchor help fuzz commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz__subcmd__cmin_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz__subcmd__cmin_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help fuzz cmin commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz__subcmd__init_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help fuzz init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz__subcmd__list_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help fuzz list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz__subcmd__run_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz__subcmd__run_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help fuzz run commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz__subcmd__show_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz__subcmd__show_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help fuzz show commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__fuzz__subcmd__tmin_commands] )) ||
_anchor__subcmd__help__subcmd__fuzz__subcmd__tmin_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help fuzz tmin commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl_commands] )) ||
_anchor__subcmd__help__subcmd__idl_commands() {
    local commands; commands=(
'init:Initializes a program'\''s IDL account. Can only be run once' \
'upgrade:Upgrades the IDL to the new file. An alias for first writing and then then setting the idl buffer account' \
'build:Generates the IDL for the program using the compilation method' \
'fetch:Fetches an IDL for the given program from a cluster' \
'fetch-historical:Fetches historical IDL versions for the given program from a cluster' \
'convert:Convert legacy IDLs (pre Anchor 0.30) to the new IDL spec' \
'type:Generate TypeScript type for the IDL' \
'close:Close a metadata account and recover rent' \
'create-buffer:Create a buffer account for metadata' \
'set-buffer-authority:Set a new authority on a buffer account' \
'write-buffer:Write metadata using a buffer account' \
    )
    _describe -t commands 'anchor help idl commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__build_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__build_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl build commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__close_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__convert_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__convert_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl convert commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__create-buffer_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__create-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl create-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__fetch_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__fetch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl fetch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__fetch-historical_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__fetch-historical_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl fetch-historical commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__init_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__set-buffer-authority_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__set-buffer-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl set-buffer-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__type_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__type_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl type commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__upgrade_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__idl__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__help__subcmd__idl__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help idl write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__init_commands] )) ||
_anchor__subcmd__help__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keygen_commands] )) ||
_anchor__subcmd__help__subcmd__keygen_commands() {
    local commands; commands=(
'new:Generate a new keypair' \
'pubkey:Display the pubkey for a given keypair' \
'recover:Recover a keypair from a seed phrase' \
'verify:Verify a keypair can sign and verify a message' \
    )
    _describe -t commands 'anchor help keygen commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keygen__subcmd__new_commands] )) ||
_anchor__subcmd__help__subcmd__keygen__subcmd__new_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help keygen new commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keygen__subcmd__pubkey_commands] )) ||
_anchor__subcmd__help__subcmd__keygen__subcmd__pubkey_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help keygen pubkey commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keygen__subcmd__recover_commands] )) ||
_anchor__subcmd__help__subcmd__keygen__subcmd__recover_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help keygen recover commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keygen__subcmd__verify_commands] )) ||
_anchor__subcmd__help__subcmd__keygen__subcmd__verify_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help keygen verify commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keys_commands] )) ||
_anchor__subcmd__help__subcmd__keys_commands() {
    local commands; commands=(
'list:List all of the program keys' \
'sync:Sync program \`declare_id!\` pubkeys with the program'\''s actual pubkey' \
    )
    _describe -t commands 'anchor help keys commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keys__subcmd__list_commands] )) ||
_anchor__subcmd__help__subcmd__keys__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help keys list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__keys__subcmd__sync_commands] )) ||
_anchor__subcmd__help__subcmd__keys__subcmd__sync_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help keys sync commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl_commands() {
    local commands; commands=(
'close:\[DEPRECATED\] Close the legacy IDL account and recover rent' \
'write-buffer:\[DEPRECATED\] Write an IDL into a legacy buffer account. Use with set-buffer to upgrade' \
'set-buffer:\[DEPRECATED\] Set a new IDL buffer for the program' \
'set-authority:\[DEPRECATED\] Set a new authority on the legacy IDL account' \
'erase-authority:\[DEPRECATED\] Remove the ability to modify the legacy IDL account' \
'authority:\[DEPRECATED\] Output the authority for the legacy IDL account' \
'init:\[DEPRECATED\] Initialize the legacy on-chain IDL account for the first time' \
'upgrade:\[DEPRECATED\] Upgrade the legacy IDL (write buffer → set buffer → close buffer)' \
'fetch:\[DEPRECATED\] Fetch the IDL from a legacy on-chain IdlAccount' \
    )
    _describe -t commands 'anchor help legacy-idl commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__authority_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__close_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__erase-authority_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__erase-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl erase-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__fetch_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__fetch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl fetch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__init_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__set-authority_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__set-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl set-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__set-buffer_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__set-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl set-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__upgrade_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__legacy-idl__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__help__subcmd__legacy-idl__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help legacy-idl write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__localnet_commands] )) ||
_anchor__subcmd__help__subcmd__localnet_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help localnet commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__logs_commands] )) ||
_anchor__subcmd__help__subcmd__logs_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help logs commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__migrate_commands] )) ||
_anchor__subcmd__help__subcmd__migrate_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help migrate commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__new_commands] )) ||
_anchor__subcmd__help__subcmd__new_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help new commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program_commands] )) ||
_anchor__subcmd__help__subcmd__program_commands() {
    local commands; commands=(
'deploy:Deploy an upgradeable program' \
'write-buffer:Write a program into a buffer account' \
'set-buffer-authority:Set a new buffer authority' \
'set-upgrade-authority:Set a new program authority' \
'show:Display information about a buffer or program' \
'upgrade:Upgrade an upgradeable program' \
'dump:Write the program data to a file' \
'close:Close a program or buffer account and withdraw all lamports' \
'extend:Extend the length of an upgradeable program' \
    )
    _describe -t commands 'anchor help program commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__close_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__deploy_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__deploy_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program deploy commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__dump_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__dump_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program dump commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__extend_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__extend_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program extend commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__set-buffer-authority_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__set-buffer-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program set-buffer-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__set-upgrade-authority_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__set-upgrade-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program set-upgrade-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__show_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__show_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program show commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__upgrade_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__program__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__help__subcmd__program__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help program write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__run_commands] )) ||
_anchor__subcmd__help__subcmd__run_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help run commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__shell_commands] )) ||
_anchor__subcmd__help__subcmd__shell_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help shell commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__show-account_commands] )) ||
_anchor__subcmd__help__subcmd__show-account_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help show-account commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__test_commands] )) ||
_anchor__subcmd__help__subcmd__test_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help test commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__upgrade_commands] )) ||
_anchor__subcmd__help__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__help__subcmd__verify_commands] )) ||
_anchor__subcmd__help__subcmd__verify_commands() {
    local commands; commands=()
    _describe -t commands 'anchor help verify commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl_commands] )) ||
_anchor__subcmd__idl_commands() {
    local commands; commands=(
'init:Initializes a program'\''s IDL account. Can only be run once' \
'upgrade:Upgrades the IDL to the new file. An alias for first writing and then then setting the idl buffer account' \
'build:Generates the IDL for the program using the compilation method' \
'fetch:Fetches an IDL for the given program from a cluster' \
'fetch-historical:Fetches historical IDL versions for the given program from a cluster' \
'convert:Convert legacy IDLs (pre Anchor 0.30) to the new IDL spec' \
'type:Generate TypeScript type for the IDL' \
'close:Close a metadata account and recover rent' \
'create-buffer:Create a buffer account for metadata' \
'set-buffer-authority:Set a new authority on a buffer account' \
'write-buffer:Write metadata using a buffer account' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor idl commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__build_commands] )) ||
_anchor__subcmd__idl__subcmd__build_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl build commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__close_commands] )) ||
_anchor__subcmd__idl__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__convert_commands] )) ||
_anchor__subcmd__idl__subcmd__convert_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl convert commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__create-buffer_commands] )) ||
_anchor__subcmd__idl__subcmd__create-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl create-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__fetch_commands] )) ||
_anchor__subcmd__idl__subcmd__fetch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl fetch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__fetch-historical_commands] )) ||
_anchor__subcmd__idl__subcmd__fetch-historical_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl fetch-historical commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help_commands] )) ||
_anchor__subcmd__idl__subcmd__help_commands() {
    local commands; commands=(
'init:Initializes a program'\''s IDL account. Can only be run once' \
'upgrade:Upgrades the IDL to the new file. An alias for first writing and then then setting the idl buffer account' \
'build:Generates the IDL for the program using the compilation method' \
'fetch:Fetches an IDL for the given program from a cluster' \
'fetch-historical:Fetches historical IDL versions for the given program from a cluster' \
'convert:Convert legacy IDLs (pre Anchor 0.30) to the new IDL spec' \
'type:Generate TypeScript type for the IDL' \
'close:Close a metadata account and recover rent' \
'create-buffer:Create a buffer account for metadata' \
'set-buffer-authority:Set a new authority on a buffer account' \
'write-buffer:Write metadata using a buffer account' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor idl help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__build_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__build_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help build commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__close_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__convert_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__convert_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help convert commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__create-buffer_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__create-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help create-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__fetch_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__fetch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help fetch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__fetch-historical_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__fetch-historical_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help fetch-historical commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__init_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__set-buffer-authority_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__set-buffer-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help set-buffer-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__type_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__type_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help type commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__upgrade_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__help__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__idl__subcmd__help__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl help write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__init_commands] )) ||
_anchor__subcmd__idl__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__set-buffer-authority_commands] )) ||
_anchor__subcmd__idl__subcmd__set-buffer-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl set-buffer-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__type_commands] )) ||
_anchor__subcmd__idl__subcmd__type_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl type commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__upgrade_commands] )) ||
_anchor__subcmd__idl__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__idl__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__idl__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor idl write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__init_commands] )) ||
_anchor__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen_commands] )) ||
_anchor__subcmd__keygen_commands() {
    local commands; commands=(
'new:Generate a new keypair' \
'pubkey:Display the pubkey for a given keypair' \
'recover:Recover a keypair from a seed phrase' \
'verify:Verify a keypair can sign and verify a message' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor keygen commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__help_commands] )) ||
_anchor__subcmd__keygen__subcmd__help_commands() {
    local commands; commands=(
'new:Generate a new keypair' \
'pubkey:Display the pubkey for a given keypair' \
'recover:Recover a keypair from a seed phrase' \
'verify:Verify a keypair can sign and verify a message' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor keygen help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__keygen__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__help__subcmd__new_commands] )) ||
_anchor__subcmd__keygen__subcmd__help__subcmd__new_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen help new commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__help__subcmd__pubkey_commands] )) ||
_anchor__subcmd__keygen__subcmd__help__subcmd__pubkey_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen help pubkey commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__help__subcmd__recover_commands] )) ||
_anchor__subcmd__keygen__subcmd__help__subcmd__recover_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen help recover commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__help__subcmd__verify_commands] )) ||
_anchor__subcmd__keygen__subcmd__help__subcmd__verify_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen help verify commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__new_commands] )) ||
_anchor__subcmd__keygen__subcmd__new_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen new commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__pubkey_commands] )) ||
_anchor__subcmd__keygen__subcmd__pubkey_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen pubkey commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__recover_commands] )) ||
_anchor__subcmd__keygen__subcmd__recover_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen recover commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keygen__subcmd__verify_commands] )) ||
_anchor__subcmd__keygen__subcmd__verify_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keygen verify commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys_commands] )) ||
_anchor__subcmd__keys_commands() {
    local commands; commands=(
'list:List all of the program keys' \
'sync:Sync program \`declare_id!\` pubkeys with the program'\''s actual pubkey' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor keys commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys__subcmd__help_commands] )) ||
_anchor__subcmd__keys__subcmd__help_commands() {
    local commands; commands=(
'list:List all of the program keys' \
'sync:Sync program \`declare_id!\` pubkeys with the program'\''s actual pubkey' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor keys help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__keys__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keys help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys__subcmd__help__subcmd__list_commands] )) ||
_anchor__subcmd__keys__subcmd__help__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keys help list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys__subcmd__help__subcmd__sync_commands] )) ||
_anchor__subcmd__keys__subcmd__help__subcmd__sync_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keys help sync commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys__subcmd__list_commands] )) ||
_anchor__subcmd__keys__subcmd__list_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keys list commands' commands "$@"
}
(( $+functions[_anchor__subcmd__keys__subcmd__sync_commands] )) ||
_anchor__subcmd__keys__subcmd__sync_commands() {
    local commands; commands=()
    _describe -t commands 'anchor keys sync commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl_commands] )) ||
_anchor__subcmd__legacy-idl_commands() {
    local commands; commands=(
'close:\[DEPRECATED\] Close the legacy IDL account and recover rent' \
'write-buffer:\[DEPRECATED\] Write an IDL into a legacy buffer account. Use with set-buffer to upgrade' \
'set-buffer:\[DEPRECATED\] Set a new IDL buffer for the program' \
'set-authority:\[DEPRECATED\] Set a new authority on the legacy IDL account' \
'erase-authority:\[DEPRECATED\] Remove the ability to modify the legacy IDL account' \
'authority:\[DEPRECATED\] Output the authority for the legacy IDL account' \
'init:\[DEPRECATED\] Initialize the legacy on-chain IDL account for the first time' \
'upgrade:\[DEPRECATED\] Upgrade the legacy IDL (write buffer → set buffer → close buffer)' \
'fetch:\[DEPRECATED\] Fetch the IDL from a legacy on-chain IdlAccount' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor legacy-idl commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__authority_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__close_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__erase-authority_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__erase-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl erase-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__fetch_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__fetch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl fetch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help_commands() {
    local commands; commands=(
'close:\[DEPRECATED\] Close the legacy IDL account and recover rent' \
'write-buffer:\[DEPRECATED\] Write an IDL into a legacy buffer account. Use with set-buffer to upgrade' \
'set-buffer:\[DEPRECATED\] Set a new IDL buffer for the program' \
'set-authority:\[DEPRECATED\] Set a new authority on the legacy IDL account' \
'erase-authority:\[DEPRECATED\] Remove the ability to modify the legacy IDL account' \
'authority:\[DEPRECATED\] Output the authority for the legacy IDL account' \
'init:\[DEPRECATED\] Initialize the legacy on-chain IDL account for the first time' \
'upgrade:\[DEPRECATED\] Upgrade the legacy IDL (write buffer → set buffer → close buffer)' \
'fetch:\[DEPRECATED\] Fetch the IDL from a legacy on-chain IdlAccount' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor legacy-idl help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__authority_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__close_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__erase-authority_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__erase-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help erase-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__fetch_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__fetch_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help fetch commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__init_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__set-authority_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__set-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help set-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__set-buffer_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__set-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help set-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__upgrade_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__help__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__help__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl help write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__init_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__init_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl init commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__set-authority_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__set-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl set-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__set-buffer_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__set-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl set-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__upgrade_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__legacy-idl__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__legacy-idl__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor legacy-idl write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__localnet_commands] )) ||
_anchor__subcmd__localnet_commands() {
    local commands; commands=()
    _describe -t commands 'anchor localnet commands' commands "$@"
}
(( $+functions[_anchor__subcmd__logs_commands] )) ||
_anchor__subcmd__logs_commands() {
    local commands; commands=()
    _describe -t commands 'anchor logs commands' commands "$@"
}
(( $+functions[_anchor__subcmd__migrate_commands] )) ||
_anchor__subcmd__migrate_commands() {
    local commands; commands=()
    _describe -t commands 'anchor migrate commands' commands "$@"
}
(( $+functions[_anchor__subcmd__new_commands] )) ||
_anchor__subcmd__new_commands() {
    local commands; commands=()
    _describe -t commands 'anchor new commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program_commands] )) ||
_anchor__subcmd__program_commands() {
    local commands; commands=(
'deploy:Deploy an upgradeable program' \
'write-buffer:Write a program into a buffer account' \
'set-buffer-authority:Set a new buffer authority' \
'set-upgrade-authority:Set a new program authority' \
'show:Display information about a buffer or program' \
'upgrade:Upgrade an upgradeable program' \
'dump:Write the program data to a file' \
'close:Close a program or buffer account and withdraw all lamports' \
'extend:Extend the length of an upgradeable program' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor program commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__close_commands] )) ||
_anchor__subcmd__program__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__deploy_commands] )) ||
_anchor__subcmd__program__subcmd__deploy_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program deploy commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__dump_commands] )) ||
_anchor__subcmd__program__subcmd__dump_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program dump commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__extend_commands] )) ||
_anchor__subcmd__program__subcmd__extend_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program extend commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help_commands] )) ||
_anchor__subcmd__program__subcmd__help_commands() {
    local commands; commands=(
'deploy:Deploy an upgradeable program' \
'write-buffer:Write a program into a buffer account' \
'set-buffer-authority:Set a new buffer authority' \
'set-upgrade-authority:Set a new program authority' \
'show:Display information about a buffer or program' \
'upgrade:Upgrade an upgradeable program' \
'dump:Write the program data to a file' \
'close:Close a program or buffer account and withdraw all lamports' \
'extend:Extend the length of an upgradeable program' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'anchor program help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__close_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__close_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help close commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__deploy_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__deploy_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help deploy commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__dump_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__dump_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help dump commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__extend_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__extend_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help extend commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__help_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__help_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help help commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__set-buffer-authority_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__set-buffer-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help set-buffer-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__set-upgrade-authority_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__set-upgrade-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help set-upgrade-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__show_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__show_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help show commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__upgrade_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__help__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__program__subcmd__help__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program help write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__set-buffer-authority_commands] )) ||
_anchor__subcmd__program__subcmd__set-buffer-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program set-buffer-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__set-upgrade-authority_commands] )) ||
_anchor__subcmd__program__subcmd__set-upgrade-authority_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program set-upgrade-authority commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__show_commands] )) ||
_anchor__subcmd__program__subcmd__show_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program show commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__upgrade_commands] )) ||
_anchor__subcmd__program__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__program__subcmd__write-buffer_commands] )) ||
_anchor__subcmd__program__subcmd__write-buffer_commands() {
    local commands; commands=()
    _describe -t commands 'anchor program write-buffer commands' commands "$@"
}
(( $+functions[_anchor__subcmd__run_commands] )) ||
_anchor__subcmd__run_commands() {
    local commands; commands=()
    _describe -t commands 'anchor run commands' commands "$@"
}
(( $+functions[_anchor__subcmd__shell_commands] )) ||
_anchor__subcmd__shell_commands() {
    local commands; commands=()
    _describe -t commands 'anchor shell commands' commands "$@"
}
(( $+functions[_anchor__subcmd__show-account_commands] )) ||
_anchor__subcmd__show-account_commands() {
    local commands; commands=()
    _describe -t commands 'anchor show-account commands' commands "$@"
}
(( $+functions[_anchor__subcmd__test_commands] )) ||
_anchor__subcmd__test_commands() {
    local commands; commands=()
    _describe -t commands 'anchor test commands' commands "$@"
}
(( $+functions[_anchor__subcmd__upgrade_commands] )) ||
_anchor__subcmd__upgrade_commands() {
    local commands; commands=()
    _describe -t commands 'anchor upgrade commands' commands "$@"
}
(( $+functions[_anchor__subcmd__verify_commands] )) ||
_anchor__subcmd__verify_commands() {
    local commands; commands=()
    _describe -t commands 'anchor verify commands' commands "$@"
}

if [ "$funcstack[1]" = "_anchor" ]; then
    _anchor "$@"
else
    compdef _anchor anchor
fi
