#compdef copilot
# zsh completion for copilot
# Generated by `copilot completion zsh`. Do not edit by hand.
___copilot_is_known_path() {
    case "$1" in
        'login') return 0 ;;
        'help') return 0 ;;
        'init') return 0 ;;
        'update') return 0 ;;
        'version') return 0 ;;
        'plugin') return 0 ;;
        'plugin install') return 0 ;;
        'plugin uninstall') return 0 ;;
        'plugin update') return 0 ;;
        'plugin list') return 0 ;;
        'plugin marketplace') return 0 ;;
        'plugin marketplace add') return 0 ;;
        'plugin marketplace remove') return 0 ;;
        'plugin marketplace list') return 0 ;;
        'plugin marketplace browse') return 0 ;;
        'plugin marketplace update') return 0 ;;
        'mcp') return 0 ;;
        'mcp list') return 0 ;;
        'mcp get') return 0 ;;
        'mcp add') return 0 ;;
        'mcp remove') return 0 ;;
        'completion') return 0 ;;
        *) return 1 ;;
    esac
}

_copilot() {
    local cur prev
    cur="${words[CURRENT]}"
    prev="${words[CURRENT-1]}"

    local __required='--add-dir --add-github-mcp-tool --add-github-mcp-toolset --additional-mcp-config --agent --attachment --context --disable-mcp-server --effort --env --extension-sdk-path --header --host --interactive --log-dir --log-level --max-autopilot-continues --mode --model --name --output-format --plugin-dir --prompt --reasoning-effort --session-id --stream --timeout --tools --transport -C -i -n -p'
    local __optional='--bash-env --connect --mouse --resume --share'
    local __variadic='--allow-tool --allow-url --available-tools --deny-tool --deny-url --excluded-tools --secret-env-vars'

    # Walk words[2..CURRENT-1] (zsh arrays are 1-indexed; words[1] is the
    # command name). Value-taking flags consume tokens differently:
    #   required (--foo <v>):    always consume next token as value
    #   optional (--foo [v]):    consume next only if it isn't a flag or a
    #                            known subcommand at the current path
    #   variadic (--foo [v...]): keep consuming under the same rule
    local __path="" __i=2 __mode=none
    while (( __i < CURRENT )); do
        local __w="${words[$__i]}"
        if [[ "$__w" == "--" ]]; then
            break
        fi

        if [[ "$__mode" == "required" ]]; then
            __mode=none
            (( __i++ ))
            continue
        fi

        if [[ "$__mode" == "optional" || "$__mode" == "variadic" ]]; then
            local __candidate
            if [[ -n "$__path" ]]; then
                __candidate="$__path $__w"
            else
                __candidate="$__w"
            fi
            if [[ "$__w" == -* ]] || ___copilot_is_known_path "$__candidate"; then
                __mode=none
            else
                if [[ "$__mode" == "optional" ]]; then __mode=none; fi
                (( __i++ ))
                continue
            fi
        fi

        if [[ "$__w" == --*=* ]]; then
            : # --flag=value form, no extra skip
        elif [[ "$__w" == -* ]]; then
            if [[ " $__required " == *" $__w "* ]]; then __mode=required
            elif [[ " $__optional " == *" $__w "* ]]; then __mode=optional
            elif [[ " $__variadic " == *" $__w "* ]]; then __mode=variadic
            fi
        else
            local __candidate2
            if [[ -n "$__path" ]]; then
                __candidate2="$__path $__w"
            else
                __candidate2="$__w"
            fi
            if ___copilot_is_known_path "$__candidate2"; then
                __path="$__candidate2"
            fi
        fi
        (( __i++ ))
    done

    case "$prev" in
        --effort|--reasoning-effort)
            local -a __vals=('none' 'low' 'medium' 'high' 'xhigh' 'max')
            _describe -t values 'value' __vals
            return 0
            ;;
        --context)
            local -a __vals=('default' 'long_context')
            _describe -t values 'value' __vals
            return 0
            ;;
        --log-level)
            local -a __vals=('none' 'error' 'warning' 'info' 'debug' 'all' 'default')
            _describe -t values 'value' __vals
            return 0
            ;;
        --stream)
            local -a __vals=('on' 'off')
            _describe -t values 'value' __vals
            return 0
            ;;
        --output-format)
            local -a __vals=('text' 'json')
            _describe -t values 'value' __vals
            return 0
            ;;
        --mode)
            local -a __vals=('interactive' 'plan' 'autopilot')
            _describe -t values 'value' __vals
            return 0
            ;;
        --transport)
            local -a __vals=('stdio' 'http' 'sse')
            _describe -t values 'value' __vals
            return 0
            ;;
    esac

    local -a ___copilot_flags ___copilot_subs
    case "$__path" in
        '')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=('login:Authenticate with Copilot' 'help:Display help information' 'init:Initialize Copilot instructions' 'update:Download the latest version' 'version:Display version information' 'plugin:Manage plugins' 'mcp:Manage MCP servers' 'completion:Generate a shell completion script')
            ;;
        'login')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile' '--host:GitHub host URL (default\: https\://github.com)')
            ___copilot_subs=()
            ;;
        'help')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'init')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'update')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'version')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=('install:Install a plugin' 'uninstall:Uninstall a plugin' 'update:Update a plugin' 'list:List installed plugins' 'marketplace:Manage plugin marketplaces')
            ;;
        'plugin install')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin uninstall')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin update')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile' '--all:Update all installed plugins')
            ___copilot_subs=()
            ;;
        'plugin list')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin marketplace')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=('add:Add a marketplace' 'remove:Remove a marketplace' 'list:List registered marketplaces' 'browse:Browse plugins in a marketplace' 'update:Update marketplace plugin catalogs')
            ;;
        'plugin marketplace add')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin marketplace remove')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile' '--force:Force removal even if plugins are installed' '-f:Force removal even if plugins are installed')
            ___copilot_subs=()
            ;;
        'plugin marketplace list')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin marketplace browse')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'plugin marketplace update')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'mcp')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=('list:List configured MCP servers' 'get:Show server details' 'add:Add an MCP server' 'remove:Remove an MCP server')
            ;;
        'mcp list')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile' '--json:Output as JSON')
            ___copilot_subs=()
            ;;
        'mcp get')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile' '--json:Output as JSON' '--show-secrets:Show full environment variable and header values (masked by default)')
            ___copilot_subs=()
            ;;
        'mcp add')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile' '--transport:Server transport' '--env:Environment variable (KEY=VALUE, can be repeated)' '--header:HTTP header for remote servers, can be repeated' '--tools:Tool filter\: "*" for all, comma-separated list, or "" for none' '--timeout:Timeout in milliseconds' '--json:Output added config as JSON' '--show-secrets:Show full environment variable and header values in output, masked by default')
            ___copilot_subs=()
            ;;
        'mcp remove')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
        'completion')
            ___copilot_flags=('--version:show version information' '-v:show version information' '--interactive:Start interactive mode and automatically execute this prompt' '-i:Start interactive mode and automatically execute this prompt' '--prompt:Execute a prompt in non-interactive mode (exits after completion)' '-p:Execute a prompt in non-interactive mode (exits after completion)' '--silent:Output only the agent response (no stats), useful for scripting with -p' '-s:Output only the agent response (no stats), useful for scripting with -p' '--model:Set the AI model to use' '--effort:Set the reasoning effort level' '--reasoning-effort:Set the reasoning effort level' '--context:Set the context window tier (overrides persisted setting)' '--enable-reasoning-summaries:Request reasoning summaries for OpenAI models' '--agent:Specify a custom agent to use' '--resume:Resume from a previous session (optionally specify existing session ID, task ID, ID prefix, or name; name matching is exact, case-insensitive)' '--continue:Resume the most recent session' '--name:Set a name for the new session' '-n:Set a name for the new session' '--session-id:Resume an existing session or task by ID, or set the UUID for a new session' '--connect:Connect directly to a remote session (optionally specify session ID or task ID)' '--allow-all-tools:Allow all tools to run automatically without confirmation; required for non-interactive mode' '--allow-all-paths:Disable file path verification and allow access to any path' '--disallow-temp-dir:Prevent automatic access to the system temporary directory' '--no-custom-instructions:Disable loading of custom instructions from AGENTS.md and related files' '--no-auto-update:Disable downloading CLI update automatically (disabled by default in CI environments)' '--no-ask-user:Disable the ask_user tool (agent works autonomously without asking questions)' '--banner:Show the startup banner' '--no-color:Disable all color output' '--screen-reader:Enable screen reader optimizations' '--plain-diff:Disable rich diff rendering (syntax highlighting via diff tool specified by git config)' '-C:Change working directory before doing anything else' '--log-dir:Set log file directory (default\: ~/.copilot/logs/)' '--extension-sdk-path:Override the bundled @github/copilot-sdk injected into extension subprocesses with a local `copilot-sdk/` folder. Invalid paths fall back to the bundled SDK.' '--log-level:Set the log level' '--stream:Enable or disable streaming mode' '--output-format:Output format\: '\''text'\'' (default) or '\''json'\'' (JSONL, one JSON object per line)' '--share:Share session to markdown file after completion in non-interactive mode (default\: ./copilot-session-<id>.md)' '--share-gist:Share session to a secret GitHub gist after completion in non-interactive mode' '--add-dir:Add a directory to the allowed list for file access (can be used multiple times)' '--attachment:Attach a file (image or native document) to the initial prompt; only valid in non-interactive mode (can be used multiple times)' '--disable-mcp-server:Disable a specific MCP server (can be used multiple times)' '--disable-builtin-mcps:Disable all built-in MCP servers (currently\: github-mcp-server)' '--enable-all-github-mcp-tools:Enable all GitHub MCP server tools instead of the default CLI subset. Overrides --add-github-mcp-toolset and --add-github-mcp-tool options.' '--add-github-mcp-toolset:Add a toolset to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "all" for all toolsets.' '--add-github-mcp-tool:Add a tool to enable for the GitHub MCP server instead of the default CLI subset (can be used multiple times). Use "*" for all tools.' '--plugin-dir:Load a plugin from a local directory (can be used multiple times)' '--additional-mcp-config:Additional MCP servers configuration as JSON string or file path (prefix with @) (can be used multiple times; augments config from ~/.copilot/mcp-config.json for this session)' '--allow-tool:Tools the CLI has permission to use; will not prompt for permission' '--deny-tool:Tools the CLI does not have permission to use; will not prompt for permission' '--available-tools:Only these tools will be available to the model' '--excluded-tools:These tools will not be available to the model' '--secret-env-vars:Environment variable names whose values are stripped from shell and MCP server environments and redacted from output (e.g., --secret-env-vars=MY_KEY,OTHER_KEY)' '--allow-url:Allow access to specific URLs or domains' '--deny-url:Deny access to specific URLs or domains, takes precedence over --allow-url' '--allow-all-urls:Allow access to all URLs without confirmation' '--allow-all:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--yolo:Enable all permissions (equivalent to --allow-all-tools --allow-all-paths --allow-all-urls)' '--max-autopilot-continues:Maximum number of continuation messages in autopilot mode' '--mode:Set the initial agent mode' '--autopilot:Start in autopilot mode' '--plan:Start in plan mode' '--experimental:Enable experimental features' '--no-experimental:Disable experimental features' '--bash-env:Enable BASH_ENV support for bash shells (on|off)' '--no-bash-env:Disable BASH_ENV support for bash shells' '--mouse:Enable mouse support in alt screen mode (on|off)' '--no-mouse:Disable mouse support in alt screen mode' '--acp:Start as Agent Client Protocol server' '--remote:Enable remote control of your session from GitHub web and mobile' '--no-remote:Disable remote control of your session from GitHub web and mobile')
            ___copilot_subs=()
            ;;
    esac

    if [[ "$cur" == -* ]]; then
        _describe -t flags 'flag' ___copilot_flags
    else
        _describe -t commands 'command' ___copilot_subs
    fi
    return 0
}

_copilot "$@"
