Skip to content

Conversation

@sagarpandey88
Copy link

@sagarpandey88 sagarpandey88 commented Jan 12, 2026

Why:

Closes:

What's being changed (if available, include any code snippets, screenshots, or gifs):

Check off the following:

  • A subject matter expert (SME) has reviewed the technical accuracy of the content in this PR. In most cases, the author can be the SME. Open source contributions may require an SME review from GitHub staff.
  • The changes in this PR meet the docs fundamentals that are required for all content.
  • All CI checks are passing and the changes look good in the review environment.

@github-actions
Copy link
Contributor

Thanks for submitting a PR to the GitHub Docs project!

In order to review and merge PRs most efficiently, we require that all PRs grant maintainer edit access before we review them. For information on how to do this, see the documentation.

@github-actions github-actions bot added the triage Do not begin working on this issue until triaged by the team label Jan 12, 2026
@github-actions
Copy link
Contributor

How to review these changes 👓

Thank you for your contribution. To review these changes, choose one of the following options:

A Hubber will need to deploy your changes internally to review.

Table of review links

Note: Please update the URL for your staging server or codespace.

The table shows the files in the content directory that were changed in this pull request. This helps you review your changes on a staging server. Changes to the data directory are not included in this table.

Source Review Production What Changed
copilot/how-tos/use-copilot-agents/use-copilot-cli.md fpt
ghec
fpt
ghec

Key: fpt: Free, Pro, Team; ghec: GitHub Enterprise Cloud; ghes: GitHub Enterprise Server

🤖 This comment is automatically generated.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds comprehensive documentation for GitHub Copilot CLI parameters and in-session commands by consolidating reference information into two well-organized tables. This addresses issue #42356 and provides users with a clear reference for both command-line options and interactive session commands.

Changes:

  • Added "CLI parameters" section with a table documenting command-line flags and options
  • Added "In-session commands" section with a table documenting slash commands and interactive features
  • Included examples for each parameter and command to aid user understanding

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +118 to +131
| `/list-dirs` | Display all allowed directories for file access | `/list-dirs` |
| `/login` | Log in to Copilot | `/login` |
| `/logout` | Log out of Copilot | `/logout` |
| `/mcp [show, add, edit, delete, disable, enable] [server-name]` | Manage MCP servers and configurations | `/mcp add` |
| `/model [model]` | Select AI model to use | `/model gpt-5-mini` |
| `/reset-allowed-tools` | Reset the list of allowed tools during the session | `/reset-allowed-tools` |
| `/session` | Show information about the current CLI session | `/session` |
| `/skills [list, info, add, remove, reload] [args...]` | Manage skills for enhanced capabilities | `/skills list` |
| `/terminal-setup` | Configure terminal for multiline input support | `/terminal-setup` |
| `/theme [show, set, list] [auto, dark, light]` | View or configure terminal theme | `/theme set dark` |
| `/usage` | Display session usage metrics and statistics | `/usage` |
| `/user [show, list, switch]` | Manage GitHub user list | `/user list` |
| `?` | Display interactive help and available commands | `?` |
| `!<shell command>` | Run a shell command directly from the prompt without calling the model | `!git clone https://github.com/github/copilot-cli` |
Copy link

Copilot AI Jan 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The descriptions in this table are inconsistently punctuated. Some descriptions end with periods while others don't. For consistency and proper documentation style, all descriptions should either consistently include or exclude terminal periods. Based on standard documentation practices, all descriptions should end with periods since they are complete phrases describing actions.

Suggested change
| `/list-dirs` | Display all allowed directories for file access | `/list-dirs` |
| `/login` | Log in to Copilot | `/login` |
| `/logout` | Log out of Copilot | `/logout` |
| `/mcp [show, add, edit, delete, disable, enable] [server-name]` | Manage MCP servers and configurations | `/mcp add` |
| `/model [model]` | Select AI model to use | `/model gpt-5-mini` |
| `/reset-allowed-tools` | Reset the list of allowed tools during the session | `/reset-allowed-tools` |
| `/session` | Show information about the current CLI session | `/session` |
| `/skills [list, info, add, remove, reload] [args...]` | Manage skills for enhanced capabilities | `/skills list` |
| `/terminal-setup` | Configure terminal for multiline input support | `/terminal-setup` |
| `/theme [show, set, list] [auto, dark, light]` | View or configure terminal theme | `/theme set dark` |
| `/usage` | Display session usage metrics and statistics | `/usage` |
| `/user [show, list, switch]` | Manage GitHub user list | `/user list` |
| `?` | Display interactive help and available commands | `?` |
| `!<shell command>` | Run a shell command directly from the prompt without calling the model | `!git clone https://github.com/github/copilot-cli` |
| `/list-dirs` | Display all allowed directories for file access. | `/list-dirs` |
| `/login` | Log in to Copilot. | `/login` |
| `/logout` | Log out of Copilot. | `/logout` |
| `/mcp [show, add, edit, delete, disable, enable] [server-name]` | Manage MCP servers and configurations. | `/mcp add` |
| `/model [model]` | Select AI model to use. | `/model gpt-5-mini` |
| `/reset-allowed-tools` | Reset the list of allowed tools during the session. | `/reset-allowed-tools` |
| `/session` | Show information about the current CLI session. | `/session` |
| `/skills [list, info, add, remove, reload] [args...]` | Manage skills for enhanced capabilities. | `/skills list` |
| `/terminal-setup` | Configure terminal for multiline input support. | `/terminal-setup` |
| `/theme [show, set, list] [auto, dark, light]` | View or configure terminal theme. | `/theme set dark` |
| `/usage` | Display session usage metrics and statistics. | `/usage` |
| `/user [show, list, switch]` | Manage GitHub user list. | `/user list` |
| `?` | Display interactive help and available commands. | `?` |
| `!<shell command>` | Run a shell command directly from the prompt without calling the model. | `!git clone https://github.com/github/copilot-cli` |

Copilot uses AI. Check for mistakes.
Comment on lines +84 to +98
| `--agent=<name>` | Use a named custom agent for this run. | `copilot --agent=refactor-agent --prompt "Refactor this code block"` |
| `-p "<text>"` or `--prompt "<text>"` | Provide a prompt non-interactively (non-interactive mode exits after completion). | `copilot -p "Run tests and fix failures"` |
| `-i "<text>"` or `--interactive "<text>"` | Start interactive mode and automatically execute a prompt. | `copilot -i "Fix the bug in main.js"` |
| `--resume` | Resume a previously saved interactive session (session picker). | `copilot --resume` |
| `--continue` | Quickly resume the most recently closed session. | `copilot --continue` |
| `--model <model>` | Start with a specific model. | `copilot --model gpt-5` |
| `--add-dir <path>` (repeatable) | Allow access to one or more directories by repeating the flag. | `copilot --add-dir /home/user/projects --add-dir ~/workspace` |
| `--allow-all-paths` | Disable path verification for this run (trust all filesystem paths). | `copilot --allow-all-paths` |
| `--allow-tool '<tool>'` | Allow a specific tool or tool pattern. | `copilot --allow-tool 'write'` |
| `--deny-tool '<tool>'` | Deny a specific tool (can be used alongside `--allow-tool`). | `copilot --deny-tool 'MyMCP(denied_tool)' --allow-tool 'MyMCP'` |
| `--allow-all-tools` | Allow all tools without per-command approval for this run. | `copilot --allow-all-tools --resume` |
| `--allow-url <domain>` (repeatable) | Pre-approve one or more domains for network access by repeating the flag. | `copilot --allow-url github.com --allow-url api.github.com` |
| `--deny-url <url>` | Deny network access to a specific URL/domain. | `copilot --deny-url malicious-site.com` |
| `--allow-all-urls` | Allow all URLs without confirmation. | `copilot --allow-all-urls` |
| `--help` or `help` | Show CLI help and available commands. | `copilot help` |
Copy link

Copilot AI Jan 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The descriptions in this table are inconsistently punctuated. Some descriptions end with periods while others don't. For consistency and proper documentation style, all descriptions should end with periods since they are complete phrases describing actions. This follows the pattern used in other documentation tables in the repository.

Copilot uses AI. Check for mistakes.
| `/feedback` | Provide feedback about the CLI | `/feedback` |
| `/help` | Show help for interactive commands | `/help` |
| `/list-dirs` | Display all allowed directories for file access | `/list-dirs` |
| `/login` | Log in to Copilot | `/login` |
Copy link

Copilot AI Jan 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word "Copilot" should use the variable instead of hardcoded text. According to the coding guidelines, you should always use Liquid syntax variables rather than text if a variable has been defined. Replace "Copilot" with the appropriate variable such as {% data variables.product.prodname_copilot_short %}.

Copilot generated this review using guidance from repository custom instructions.
| `/help` | Show help for interactive commands | `/help` |
| `/list-dirs` | Display all allowed directories for file access | `/list-dirs` |
| `/login` | Log in to Copilot | `/login` |
| `/logout` | Log out of Copilot | `/logout` |
Copy link

Copilot AI Jan 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word "Copilot" should use the variable instead of hardcoded text. According to the coding guidelines, you should always use Liquid syntax variables rather than text if a variable has been defined. Replace "Copilot" with the appropriate variable such as {% data variables.product.prodname_copilot_short %}.

Copilot generated this review using guidance from repository custom instructions.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

triage Do not begin working on this issue until triaged by the team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant