Usage: copilot [options] [command]
GitHub Copilot CLI - An AI-powered coding assistant
Options:
--add-dir <directory> Add a directory to the allowed list for file access (can be used multiple times)
--allow-all-tools Allow all tools to run automatically without confirmation; required for non-interactive mode (env: COPILOT_ALLOW_ALL)
--allow-tool [tools...] Allow specific tools
--banner Always show the animated banner on startup
--deny-tool [tools...] Deny specific tools, takes precedence over --allow-tool or --allow-all-tools
--disable-mcp-server <server-name> Disable a specific MCP server (can be used multiple times)
-h, --help display help for command
--log-dir <directory> Set log file directory (default: ~/.copilot/logs/)
--log-level <level> Set the log level (error, warning, info, debug, all, default, none)
--no-color Disable all color output
-p, --prompt <text> Execute a prompt directly without interactive mode
--resume [sessionId] Resume from a previous session (optionally specify session ID)
--screen-reader Enable screen reader optimizations
-v, --version show version information
Commands:
help [topic] Display help information
Help Topics:
config Configuration Settings
environment Environment Variables
logging Logging
permissions Tool Permissions
Examples:
# Start interactive mode
$ copilot
# Execute a prompt directly
$ copilot -p "Fix the bug in main.js" --allow-all-tools
# Resume the latest session
$ copilot --resume
# Resume a specific session by ID
$ copilot --resume session-id
# Resume with auto-approval
$ copilot --allow-all-tools --resume
# Show the animated banner
$ copilot --banner
# Set logging to ./logs
$ copilot --log-dir ./logs
# Enable debug level logging
$ copilot --log-level debug
# Allow access to additional directory
$ copilot --add-dir /home/user/projects
# Allow multiple directories
$ copilot --add-dir ~/workspace --add-dir /tmp
# Allow touch commands
$ copilot --allow-tool 'shell(touch)'
# Deny git push commands
$ copilot --deny-tool 'shell(git push)'
# Allow all file editing
$ copilot --allow-tool 'write'
# Allow all but one specific tool from MCP server with name "MyMCP"
$ copilot --deny-tool 'MyMCP(denied_tool)' --allow-tool 'MyMCP'
Interactive Mode Commands:
/add-dir <directory> Add a directory to the allowed list for file access
/clear Clear chat history on the screen
/cwd [directory] Change working directory or show current directory
/exit Exit the CLI
/feedback Provide feedback about the CLI
/help Show help for interactive commands
/list-dirs Display all allowed directories for file access
/login Log in to Copilot
/logout Log out of Copilot
/mcp [show|add|edit|delete|disable|enable] [server-name] Manage MCP server configuration
/reset-allowed-tools Reset the list of allowed tools
/session Show information about the current CLI session
/theme [show|set|list] [auto|dark|light] View or configure terminal theme
/user [show|list|switch] Manage GitHub user list
CARVIEW |
Select Language
HTTP/2 200
date: Fri, 10 Oct 2025 00:15:49 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
etag: W/"29b488a61cc86c3d6f5f2786a4a3eb7e"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: origin-when-cross-origin, strict-origin-when-cross-origin
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com github.githubassets.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com wss://alive-staging.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com marketplace-screenshots.githubusercontent.com/ copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=2OZyjcY7FAfrWVxeDEzCSaWRMaplhOLX5WRRMZhr8lpLNuU9Tdk0kMcQMnA%2BvU5%2BLp8q880FmBRY0PM2QJ5WRo8zty2of5rTmAG7KV257%2BdbovuuR2Bkdn7RMwAtzPcNL2xl96l33u%2FPSlun27HKqrN1S6Ylbyg%2FsNTv4TffUXGSkiwGD%2FhGCT3LKRuPOS9L09jL4dgte%2FWa5bWzAna0SEFfD4gUlaF73vgF9ph4DAPGGAxWEkaXfj%2FnOHZ9kqiBA1Jws%2BTpzZYssD9hgK9eLQ%3D%3D--lVGr7n6hx1vsPWhF--08X3N4JwWDAnBvMwTZhU9g%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.1740316170.1760055348; Path=/; Domain=github.com; Expires=Sat, 10 Oct 2026 00:15:48 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Sat, 10 Oct 2026 00:15:48 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: C8DE:2C2AE3:1106845:1485CD9:68E85034
copilot-cli-help.md · GitHub
Show Gist options
Save simonw/bc739b8c67aa6e7a5f4f519942e66671 to your computer and use it in GitHub Desktop.
{{ message }}
Instantly share code, notes, and snippets.
simonw/copilot-cli-help.md Secret
Created
September 26, 2025 00:04
-
Star
5
(5)
You must be signed in to star a gist -
Fork
0
(0)
You must be signed in to fork a gist
-
Save simonw/bc739b8c67aa6e7a5f4f519942e66671 to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can’t perform that action at this time.