cadre-ai 4.2.0 → 4.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/.codex-plugin/plugin.json +1 -1
- package/CHANGELOG.md +30 -0
- package/README.md +26 -24
- package/agents/cadre-phase-worker.md +4 -0
- package/agents/cadre-task-worker.md +4 -0
- package/dist/cadre-cli.mjs +24 -15
- package/dist/cadre-mcp.mjs +2954 -2607
- package/package.json +2 -2
- package/skills/implement/SKILL.md +8 -0
- package/skills/implement/references/decisions.md +33 -0
- package/skills/implement/references/parallel-workers.md +4 -0
- package/skills/implement/references/resume-recovery.md +2 -0
- package/skills/quick/SKILL.md +3 -34
- package/skills/quick/agents/openai.yaml +1 -1
- package/skills/quick/references/bounded-work.md +36 -0
- package/skills/refresh/SKILL.md +6 -0
- package/skills/revert/SKILL.md +1 -1
- package/skills/review/SKILL.md +4 -0
- package/skills/revise/SKILL.md +6 -0
- package/skills/start/SKILL.md +15 -0
- package/skills/start/agents/openai.yaml +4 -0
- package/skills/track/SKILL.md +8 -2
- package/skills/wisp/SKILL.md +3 -3
- package/templates/{v8 → v9}/init/workflow.md +11 -0
- package/templates/{v8 → v9}/track/dependency-context.json +1 -1
- package/templates/v9/track/design.md +32 -0
- package/templates/{v8 → v9}/track/spec.md +4 -0
- package/templates/{v8 → v9}/track/state.json +8 -2
- /package/templates/{v8 → v9}/init/archive/.gitkeep +0 -0
- /package/templates/{v8 → v9}/init/gitignore.template +0 -0
- /package/templates/{v8 → v9}/init/guidelines.md +0 -0
- /package/templates/{v8 → v9}/init/operations/.gitkeep +0 -0
- /package/templates/{v8 → v9}/init/patterns/index.md +0 -0
- /package/templates/{v8 → v9}/init/product.md +0 -0
- /package/templates/{v8 → v9}/init/project.json +0 -0
- /package/templates/{v8 → v9}/init/refreshes/.gitkeep +0 -0
- /package/templates/{v8 → v9}/init/styleguides/general.md +0 -0
- /package/templates/{v8 → v9}/init/styleguides/language.md +0 -0
- /package/templates/{v8 → v9}/init/tech-stack.md +0 -0
- /package/templates/{v8 → v9}/init/tracks/.gitkeep +0 -0
- /package/templates/{v8 → v9}/init/tracks.md +0 -0
- /package/templates/{v8 → v9}/init/wisps/.gitkeep +0 -0
- /package/templates/{v8 → v9}/project/pattern.md +0 -0
- /package/templates/{v8 → v9}/project/refresh-operation.json +0 -0
- /package/templates/{v8 → v9}/project/refresh.md +0 -0
- /package/templates/{v8 → v9}/quick/record.json +0 -0
- /package/templates/{v8 → v9}/styleguides/dart.md +0 -0
- /package/templates/{v8 → v9}/styleguides/flutter.md +0 -0
- /package/templates/{v8 → v9}/styleguides/go.md +0 -0
- /package/templates/{v8 → v9}/styleguides/gradle.md +0 -0
- /package/templates/{v8 → v9}/styleguides/html-css.md +0 -0
- /package/templates/{v8 → v9}/styleguides/index.md +0 -0
- /package/templates/{v8 → v9}/styleguides/java.md +0 -0
- /package/templates/{v8 → v9}/styleguides/javascript.md +0 -0
- /package/templates/{v8 → v9}/styleguides/kotlin.md +0 -0
- /package/templates/{v8 → v9}/styleguides/maven.md +0 -0
- /package/templates/{v8 → v9}/styleguides/python.md +0 -0
- /package/templates/{v8 → v9}/styleguides/react.md +0 -0
- /package/templates/{v8 → v9}/styleguides/swift.md +0 -0
- /package/templates/{v8 → v9}/styleguides/swiftui.md +0 -0
- /package/templates/{v8 → v9}/styleguides/typescript.md +0 -0
- /package/templates/{v8 → v9}/track/bug.md +0 -0
- /package/templates/{v8 → v9}/track/execution.json +0 -0
- /package/templates/{v8 → v9}/track/learning.md +0 -0
- /package/templates/{v8 → v9}/track/plan.md +0 -0
- /package/templates/{v8 → v9}/track/revert-operation.json +0 -0
- /package/templates/{v8 → v9}/track/revise-operation.json +0 -0
- /package/templates/{v8 → v9}/track/revision.md +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,35 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [4.3.0] - 2026-12-03
|
|
4
|
+
|
|
5
|
+
Start is the primary command for new work. Use Cadre: Start in Codex,
|
|
6
|
+
`/cadre:start` in Claude Code, or `/cadre-start` in Zed. Start inspects scope and
|
|
7
|
+
existing checkpoints before editing. Quick delivers a bounded change with one
|
|
8
|
+
final approval. Track prepares a specification, plan, and conditional design
|
|
9
|
+
for approval. You can still ask for Track directly on any size of change.
|
|
10
|
+
|
|
11
|
+
**Deprecation.** Direct `quick` shows one notice and continues in 4.3.0. Removal is
|
|
12
|
+
planned for the following release. Start uses the same bounded-work procedure.
|
|
13
|
+
Existing Quick checkpoints, records, archived history, and receipts remain usable.
|
|
14
|
+
|
|
15
|
+
**Upgrade.** Run `npm install -g cadre-ai@4.3.0`, then
|
|
16
|
+
`cadre-ai install --target all --scope user`. Reload your client (in Zed, reload
|
|
17
|
+
the workspace and open a new Agent thread). Installing enables Start. Existing
|
|
18
|
+
supported schema-2 projects, including 4.2.0 projects, adopt the v9 project
|
|
19
|
+
contract through an approved Refresh.
|
|
20
|
+
|
|
21
|
+
### Design, decisions, and integration fixes
|
|
22
|
+
|
|
23
|
+
- Add explicit implementation clarification gates and durable, digest-bound decisions that block affected execution while independent work continues.
|
|
24
|
+
- Add conditional approved design.md with template v9, provenance, revision, dependency context and retained retrieval. Verification approach references acceptance criteria without repeating them.
|
|
25
|
+
- Add opt-in technical Autopilot as Autonomous execution plus a separate decision policy. Product/external choices and final completion still need human authority. Existing Autonomous remains ask-by-default.
|
|
26
|
+
- Preserve v1–v8 templates and historical journals; adopt the new project contract through approved Refresh. The MCP catalog retains 21 tools.
|
|
27
|
+
- Enforce v9 design assessment and dependency coverage for active tracks revised through Refresh while preserving legacy context-only maintenance.
|
|
28
|
+
- Bind owned build caches to canonical project identity, accepting verified legacy temporary-path aliases without deleting outputs or adopting foreign caches.
|
|
29
|
+
- On Zed upgrades, retire exact default approvals for removed setup and archive tools. Customized rules are preserved.
|
|
30
|
+
- Adapt Zed candidate authoring to terminal tools for ignored staging paths, retaining safe quoting, exact manifests, validation, and approval before promotion.
|
|
31
|
+
- Expand the website's design and decision guide, artifact reference, release notes, navigation, search metadata, and generated sitemap coverage. Native Zed and protocol validation are reported separately; token savings remain unproven.
|
|
32
|
+
|
|
3
33
|
## [4.2.0] - 2026-11-08
|
|
4
34
|
|
|
5
35
|
### Optional telemetry
|
package/README.md
CHANGED
|
@@ -2,11 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
Cadre is a product of [Dhivon AI](https://dhivon.ai).
|
|
4
4
|
|
|
5
|
-
**Cadre 4.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
**Cadre 4.3.0** introduces Start for new work. Describe the change once. Cadre
|
|
6
|
+
verifies a bounded fix through Quick or prepares a Track specification and plan for
|
|
7
|
+
a migration or coordinated change. Invoke Track directly when you want a plan,
|
|
8
|
+
even for a small fix. Direct Quick is deprecated in 4.3.0 and scheduled for
|
|
9
|
+
removal in the following release.
|
|
10
|
+
|
|
11
|
+
Install `cadre-ai@4.3.0`, run `cadre-ai install --target all`, and reload your
|
|
12
|
+
client to discover Start. Existing supported projects adopt template v9 through an
|
|
13
|
+
approved Refresh. Quick records, receipts, and interrupted work carry forward.
|
|
10
14
|
|
|
11
15
|
Cadre is a human-governed, Git-aware delivery harness for Codex, Claude Code,
|
|
12
16
|
and Zed Agent. All three integrations are stable as of Cadre 3.9.1.
|
|
@@ -67,15 +71,14 @@ execution. See the [testing and release documentation](https://cadre.dhivon.ai/t
|
|
|
67
71
|
|
|
68
72
|
## Unified Refresh
|
|
69
73
|
|
|
70
|
-
Refresh now combines context maintenance, learning consolidation and completed-track archival under one approval, receipt and commit. Cadre 4.
|
|
74
|
+
Refresh now combines context maintenance, learning consolidation and completed-track archival under one approval, receipt and commit. Cadre 4.3.0 ships ten primary commands, the temporary Quick alias, 21 MCP tools, and template v9. The standalone archive skill and MCP tool are removed. Existing approved archive journals remain recoverable through `candidate_apply`. Older supported projects adopt the new workflow contract in an approved Refresh.
|
|
71
75
|
|
|
72
76
|
```text
|
|
73
|
-
Create →
|
|
74
|
-
|
|
75
|
-
|
|
77
|
+
Create → Start ┬→ Quick → verified outcome ────────────┐
|
|
78
|
+
└→ Track → Implement → Review ──────────┤
|
|
79
|
+
Project context, patterns, and repository changes ─────┤
|
|
76
80
|
↓
|
|
77
81
|
Refresh
|
|
78
|
-
context + learning + active seeds + archival
|
|
79
82
|
one approval · one receipt · one commit
|
|
80
83
|
```
|
|
81
84
|
|
|
@@ -86,7 +89,7 @@ batch limit. It also works without completed tracks or new guidance to add.
|
|
|
86
89
|
|
|
87
90
|
## Quick changes
|
|
88
91
|
|
|
89
|
-
|
|
92
|
+
Start selects Quick for one bounded fix, refactor, documentation change, test, or small
|
|
90
93
|
feature. It reads relevant Cadre context, implements and verifies the change,
|
|
91
94
|
then asks for one final approval of the diff and outcome record. Material scope
|
|
92
95
|
choices are discussed before editing. One local commit contains the change and
|
|
@@ -94,14 +97,12 @@ its durable record. A later approved `refresh` batch consolidates useful lessons
|
|
|
94
97
|
and moves unchanged records to `.cadre/archive/.quick/`. Routine track context
|
|
95
98
|
loads no quick history; focused search retrieves relevant outcomes when needed.
|
|
96
99
|
|
|
97
|
-
|
|
98
|
-
in Zed.
|
|
99
|
-
projects retain their workflows; enabling quick requires an approved refresh
|
|
100
|
-
adopting its contract. Wisp remains stateless exploration.
|
|
100
|
+
Select **Cadre: Start** (`$cadre:start`) in Codex, `/cadre:start` in Claude Code, or
|
|
101
|
+
`/cadre-start` in Zed. Wisp remains available for stateless exploration.
|
|
101
102
|
|
|
102
103
|
## Upcoming roadmap
|
|
103
104
|
|
|
104
|
-
Three optional capabilities are planned beyond 4.
|
|
105
|
+
Three optional capabilities are planned beyond 4.3.0:
|
|
105
106
|
|
|
106
107
|
1. **Deeper GitHub / GitLab integration** for coordinating work across multiple
|
|
107
108
|
people, including shared work status, ownership and review handoffs.
|
|
@@ -112,7 +113,7 @@ Three optional capabilities are planned beyond 4.2.0:
|
|
|
112
113
|
|
|
113
114
|
Each capability will be independently **opt-in and disabled by default**. The
|
|
114
115
|
core single-repository workflow will remain usable without enabling any of them.
|
|
115
|
-
These are upcoming roadmap items, not features included in 4.
|
|
116
|
+
These are upcoming roadmap items, not features included in 4.3.0; no delivery dates
|
|
116
117
|
are committed. See the [roadmap](https://cadre.dhivon.ai/team-and-polyrepo/).
|
|
117
118
|
|
|
118
119
|
## Capabilities
|
|
@@ -263,7 +264,7 @@ After installation or update:
|
|
|
263
264
|
- Start a new Codex conversation so the new skills and MCP tools are loaded.
|
|
264
265
|
- In Claude Code, run `/reload-plugins` or start a new session.
|
|
265
266
|
- In Zed, run `workspace: reload` from the command palette, then open a new
|
|
266
|
-
Agent thread. Confirm
|
|
267
|
+
Agent thread. Confirm the ten primary skills and Quick alias under AI → Skills and the active Cadre
|
|
267
268
|
server under AI → MCP Servers. Replacing the installed payload can leave
|
|
268
269
|
an already-open workspace with stale skill discovery until it reloads.
|
|
269
270
|
|
|
@@ -303,9 +304,9 @@ Cadre will:
|
|
|
303
304
|
### 2. Create a feature or bug track
|
|
304
305
|
|
|
305
306
|
```text
|
|
306
|
-
Codex: $cadre:
|
|
307
|
-
Claude Code: /cadre:
|
|
308
|
-
Zed Agent: /cadre-
|
|
307
|
+
Codex: $cadre:start Add passwordless login as a feature
|
|
308
|
+
Claude Code: /cadre:start Fix duplicate invoice creation as a bug
|
|
309
|
+
Zed Agent: /cadre-start Add passwordless login as a feature
|
|
309
310
|
```
|
|
310
311
|
|
|
311
312
|
Cadre proposes and approves together:
|
|
@@ -361,7 +362,8 @@ Refresh accepts one or more completed tracks in one resumable batch. It distills
|
|
|
361
362
|
| Command | Purpose |
|
|
362
363
|
| --- | --- |
|
|
363
364
|
| `create` | Initialize or resume Cadre, classify project context, initialize Git when needed, and establish approved project artifacts. |
|
|
364
|
-
| `
|
|
365
|
+
| `start` | Start or resume work through Quick or Track. |
|
|
366
|
+
| `quick` (deprecated) | Deliver a bounded change with one final approval, one combined commit, and a durable outcome record. |
|
|
365
367
|
| `track` | Create or resume a feature/bug specification, phased plan, dependency set, and learning seed. |
|
|
366
368
|
| `implement` | Execute or resume the approved phase/task DAG in parallel by default or explicitly sequentially, with worktrees, tests, learning, approvals, and commit provenance. |
|
|
367
369
|
| `review` | Review a ready track, record approved findings, add remediation phases, or complete an approved clean cycle. |
|
|
@@ -442,7 +444,7 @@ Important sources of truth:
|
|
|
442
444
|
|
|
443
445
|
## MCP capabilities
|
|
444
446
|
|
|
445
|
-
The `cadre` stdio server exposes active immutable resources at `cadre://templates/
|
|
447
|
+
The `cadre` stdio server exposes active immutable resources at `cadre://templates/v9/...` and 21 tools:
|
|
446
448
|
|
|
447
449
|
| Tool | Mutation | Purpose |
|
|
448
450
|
| --- | --- | --- |
|
|
@@ -534,7 +536,7 @@ pnpm --filter cadre-ai validate
|
|
|
534
536
|
|
|
535
537
|
### Memory format upgrade
|
|
536
538
|
|
|
537
|
-
Cadre 4.
|
|
539
|
+
Cadre 4.3.0 packages template set v9 and supports existing 4.0.0, 4.1.0 and 4.2.0 projects. Existing 3.9.0/3.9.1/3.9.2 schema-2/v5 projects need no project migration or version-only refresh. Older formats must use Cadre 3.9.0 for an approved refresh to schema-2/v5 before installing 4.3.0. Published v1–v8 templates remain unchanged in source, and terminal learning remains historical evidence. Active Pattern Seeds record revisions and exact pattern fingerprints; changed guidance requires reassessment. Task handoffs preserve decisions, failed approaches, uncertainty, and next actions alongside existing checkpoints. Use all `context_read` pages before acting, and retain source inspection and approval gates. Routine `project_status` uses summaries; request `detail: "full"` for history/graph diagnostics. Filtered/paged listings never narrow validation coverage.
|
|
538
540
|
|
|
539
541
|
Release preparation includes regression tests, package inspection, and documentation checks. Publishing still requires native installer/discovery/activation checks for Codex, Claude Code, and Zed. Local model tests and byte benchmarks do not establish universal token savings or semantic correctness of generated learning.
|
|
540
542
|
|
|
@@ -23,3 +23,7 @@ You are a Cadre phase implementation worker holding a temporary execution lease.
|
|
|
23
23
|
## Cohesive execution contract
|
|
24
24
|
|
|
25
25
|
For a new cohesive-v1 execution, main may assign a whole approved commit group. Execute its internal dependencies in order, verify every task, and return individual authorization, verification and handoff evidence with one shared product commit. Never split a group across workers or independently schedule a member before the group's external dependencies. Legacy executions keep their original task boundaries. Main owns atomic complete_group, Git integration, receipts and all Cadre state. Use only the owned build-cache path main supplies. Fast-forward integration is valid provenance; do not require a merge object.
|
|
26
|
+
|
|
27
|
+
## Material uncertainty
|
|
28
|
+
|
|
29
|
+
Before affected edits, inspect evidence. Follow established conventions for routine details; investigate unknown facts. Stop affected work and report materially different choices to main with the question, options, recommendation, affected tasks, and source evidence. Never silently select product behavior or treat confidence as authority. Main records and resolves blocking decisions; wait for its exact resolution even under Autopilot. Preserve approved design, and distinguish these blockers from harmless follow-up questions. Continue other assigned independent work only when main authorizes it.
|
|
@@ -22,3 +22,7 @@ You are a Cadre task implementation worker. The main agent is the only scheduler
|
|
|
22
22
|
## Cohesive execution contract
|
|
23
23
|
|
|
24
24
|
For a new cohesive-v1 execution, main may assign a whole approved commit group. Execute its internal dependencies in order, verify every task, and return individual authorization, verification and handoff evidence with one shared product commit. Never split a group across workers or independently schedule a member before the group's external dependencies. Legacy executions keep their original task boundaries. Main owns atomic complete_group, Git integration, receipts and all Cadre state. Use only the owned build-cache path main supplies. Fast-forward integration is valid provenance; do not require a merge object.
|
|
25
|
+
|
|
26
|
+
## Material uncertainty
|
|
27
|
+
|
|
28
|
+
Before affected edits, inspect evidence. Follow established conventions for routine details; investigate unknown facts. Stop affected work and report materially different choices to main with the question, options, recommendation, affected tasks, and source evidence. Never silently select product behavior or treat confidence as authority. Main records and resolves blocking decisions; wait for its exact resolution even under Autopilot. Preserve approved design, and distinguish these blockers from harmless follow-up questions. Continue other assigned independent work only when main authorizes it.
|
package/dist/cadre-cli.mjs
CHANGED
|
@@ -44,8 +44,8 @@ var CADRE_RUNTIME_VERSION, TEMPLATE_SET_VERSION;
|
|
|
44
44
|
var init_version = __esm({
|
|
45
45
|
"src/domain/version.ts"() {
|
|
46
46
|
"use strict";
|
|
47
|
-
CADRE_RUNTIME_VERSION = "4.
|
|
48
|
-
TEMPLATE_SET_VERSION = "
|
|
47
|
+
CADRE_RUNTIME_VERSION = "4.3.0";
|
|
48
|
+
TEMPLATE_SET_VERSION = "v9";
|
|
49
49
|
}
|
|
50
50
|
});
|
|
51
51
|
|
|
@@ -12074,6 +12074,7 @@ var TEMPLATE_IDS = [
|
|
|
12074
12074
|
"styleguide/typescript",
|
|
12075
12075
|
"track/bug",
|
|
12076
12076
|
"track/dependency-context",
|
|
12077
|
+
"track/design",
|
|
12077
12078
|
"track/execution",
|
|
12078
12079
|
"track/learning",
|
|
12079
12080
|
"track/plan",
|
|
@@ -12177,11 +12178,14 @@ var CADRE_WORKFLOWS = [
|
|
|
12177
12178
|
"revert",
|
|
12178
12179
|
"status",
|
|
12179
12180
|
"wisp",
|
|
12181
|
+
"start",
|
|
12180
12182
|
"quick"
|
|
12181
12183
|
];
|
|
12182
12184
|
var ZED_COMPATIBILITY = `## Zed compatibility
|
|
12183
12185
|
|
|
12184
|
-
Zed Agent consumes Cadre templates through tools rather than MCP resource discovery. Whenever this workflow calls \`template_get_many\`, include \`contentMode: "text"\`. Use known template IDs and descriptor tools such as \`styleguide_resolve\`; do not attempt to list or read MCP resources directly. When recommending another Cadre workflow, use its Zed command \`/cadre-<workflow>\` and never a dollar-prefixed or colon command. For MCP \`nextStep\` with plugin \`cadre\`, resolve skill \`review\` or \`implement\` to the installed \`cadre-review\` or \`cadre-implement\` skill and execute it in the same task; printing a command is not invocation
|
|
12186
|
+
Zed Agent consumes Cadre templates through tools rather than MCP resource discovery. Whenever this workflow calls \`template_get_many\`, include \`contentMode: "text"\`. Use known template IDs and descriptor tools such as \`styleguide_resolve\`; do not attempt to list or read MCP resources directly. When recommending another Cadre workflow, use its Zed command \`/cadre-<workflow>\` and never a dollar-prefixed or colon command. For MCP \`nextStep\` with plugin \`cadre\`, resolve skill \`review\` or \`implement\` to the installed \`cadre-review\` or \`cadre-implement\` skill and execute it in the same task; printing a command is not invocation.
|
|
12187
|
+
|
|
12188
|
+
Cadre candidate staging is Git-ignored and may be absent from Zed's file index. After \`candidate_stage_prepare\`, use the terminal to inspect and author the exact expected files beneath the returned \`stagePath\`; do not depend on indexed file tools for this directory. Read retained files before editing, verify the returned directory exists, and reject symlinked staging paths. Use a quoted heredoc or a structured file-writing script so candidate text is never interpreted as shell commands. If an indexed file tool cannot find the stage, switch to the terminal instead of repeating create/list/edit calls. Do not change ignore rules, create a second candidate directory, or write canonical artifacts to bypass staging. Validate through \`candidate_inspect\` or the workflow's prepare operation, then obtain the required combined approval before promotion. This fallback does not authorize editing approved recovery journals or canonical state.`;
|
|
12185
12189
|
function pathExists(path) {
|
|
12186
12190
|
try {
|
|
12187
12191
|
lstatSync3(path);
|
|
@@ -14462,16 +14466,21 @@ var CODEX_APPROVAL = 'default_tools_approval_mode = "approve"';
|
|
|
14462
14466
|
var CLAUDE_APPROVAL = "mcp__cadre__*";
|
|
14463
14467
|
var CLAUDE_SERVER_APPROVAL = "cadre";
|
|
14464
14468
|
var ZED_MCP_PERMISSION_KEYS = CADRE_MCP_TOOL_NAMES.map((name) => `mcp:cadre:${name}`);
|
|
14465
|
-
var
|
|
14466
|
-
|
|
14467
|
-
|
|
14468
|
-
|
|
14469
|
-
|
|
14470
|
-
|
|
14471
|
-
|
|
14472
|
-
|
|
14473
|
-
|
|
14474
|
-
|
|
14469
|
+
var RETIRED_ZED_PERMISSIONS = [
|
|
14470
|
+
"mcp:cadre:archive_batch_candidate",
|
|
14471
|
+
"mcp:cadre:archive_batch_record",
|
|
14472
|
+
"mcp:cadre:setup_record_commit",
|
|
14473
|
+
"mcp:cadre:setup_record_git_initialized"
|
|
14474
|
+
];
|
|
14475
|
+
function removeObsoleteZedApprovals(text, tools) {
|
|
14476
|
+
const formattingOptions = { insertSpaces: true, tabSize: 2, eol: "\n" };
|
|
14477
|
+
for (const key of RETIRED_ZED_PERMISSIONS) {
|
|
14478
|
+
const rule = tools[key];
|
|
14479
|
+
if (isRecord(rule) && rule.default === "allow" && Object.keys(rule).length === 1) {
|
|
14480
|
+
text = applyEdits(text, modify(text, ["agent", "tool_permissions", "tools", key], void 0, { formattingOptions }));
|
|
14481
|
+
}
|
|
14482
|
+
}
|
|
14483
|
+
return text;
|
|
14475
14484
|
}
|
|
14476
14485
|
function isRecord(value) {
|
|
14477
14486
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
@@ -14698,7 +14707,7 @@ function configureZedCadre(settingsPath, nodePath, mcpPath, autoApproveMcp, tele
|
|
|
14698
14707
|
{ formattingOptions }
|
|
14699
14708
|
));
|
|
14700
14709
|
}
|
|
14701
|
-
const withoutObsolete =
|
|
14710
|
+
const withoutObsolete = removeObsoleteZedApprovals(proposed, tools);
|
|
14702
14711
|
let permissionsChanged = withoutObsolete !== proposed;
|
|
14703
14712
|
proposed = withoutObsolete;
|
|
14704
14713
|
if (autoApproveMcp) {
|
|
@@ -14757,7 +14766,7 @@ function removeZedCadreServer(settingsPath, mcpPath) {
|
|
|
14757
14766
|
));
|
|
14758
14767
|
const agent = assertRecordField(root, "agent", settingsPath);
|
|
14759
14768
|
const permissions = assertRecordField(agent, "tool_permissions", settingsPath);
|
|
14760
|
-
proposed =
|
|
14769
|
+
proposed = removeObsoleteZedApprovals(proposed, assertRecordField(permissions, "tools", settingsPath));
|
|
14761
14770
|
if (proposed !== existing) atomicWrite(settingsPath, proposed.endsWith("\n") ? proposed : `${proposed}
|
|
14762
14771
|
`);
|
|
14763
14772
|
return { changed: proposed !== existing, retainedConflict: false };
|