Document Copilot CLI permissions-config.json schema and persisted approvals#44916
Document Copilot CLI permissions-config.json schema and persisted approvals#44916danmoseley wants to merge 3 commits into
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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 linksNote: Please update the URL for your staging server or codespace. The table shows the files in the
Key: fpt: Free, Pro, Team; ghec: GitHub Enterprise Cloud; ghes: GitHub Enterprise Server 🤖 This comment is automatically generated. |
There was a problem hiding this comment.
Pull request overview
Expands the GitHub Copilot CLI documentation for permissions-config.json, covering where it’s stored, how location scoping works, and the approval schema so users can reliably migrate or author persisted tool/path approvals.
Changes:
- Added detailed reference documentation for
permissions-config.json(resolution order, location keying, schema, approval kinds, and examples). - Documented command identifier and directory matching behavior used by persisted approvals.
- Added a “persisted permissions” explanation and cross-links from the tool-permissions how-to.
Show a summary per file
| File | Description |
|---|---|
| content/copilot/reference/copilot-cli-reference/cli-config-dir-reference.md | Adds full reference coverage for permissions-config.json location resolution, schema, approval kinds, and examples. |
| content/copilot/how-tos/copilot-cli/use-copilot-cli/allowing-tools.md | Explains persisted approvals and links to the detailed reference section. |
Copilot's findings
- Files reviewed: 2/2 changed files
- Comments generated: 1
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Note
This pull request was created with the help of GitHub Copilot, and parts of the documentation were AI-generated. All schema details were verified against the Copilot CLI source.
What this changes
Expands the documentation for the Copilot CLI
permissions-config.jsonfile, which was previously documented only at a surface level.content/copilot/reference/copilot-cli-reference/cli-config-dir-reference.md--config-dir→COPILOT_HOME→~/.copilot/permissions-config.json) and the legacy extensionless file.locationskeying rules (Git root; linked worktrees resolve to the main repo root; submodules use their own directory; non-Git uses the cwd).locations,tool_approvals, andallowed_directories, and every approvalkind(commands,read,write,memory,mcp,mcp-sampling,custom-tool,extension-management,extension-permission-access) with their per-kind fields (commandIdentifiers,serverName,toolName,operation,extensionName).content/copilot/how-tos/copilot-cli/use-copilot-cli/allowing-tools.md~/.copilot/permissions-config.json, with a cross-link to the reference section.Why
Users have reported that
permissions-config.jsonis hard to configure because the schema, fields, and file location were not documented in enough detail — particularly when migrating settings from other agent CLIs.Verification
The documented schema, approval kinds, and per-kind fields were checked against the product source. Examples are valid JSON and consistent with the schema table. Locally ran
npm ciand the docs content linter (lint-content) on the changed files; the repo's pre-commit content lint also passed.