@unbrained/pm-cli 2026.9.26 → 2026.9.27

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.
Files changed (130) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/CHANGELOG.md +16 -0
  3. package/dist/cli/commander-usage.js +2 -2
  4. package/dist/cli/error-guidance.js +1 -1
  5. package/dist/cli/main.js +2 -2
  6. package/dist/cli/register-setup.js +1 -1
  7. package/dist/cli/runtime/selection.d.ts +3 -1
  8. package/dist/cli/runtime/selection.js +1 -1
  9. package/dist/cli-bundle/bundle-manifest.json +160 -152
  10. package/dist/cli-bundle/chunks/{chunk-IYN4MJ2C.js → chunk-3BTJ66CB.js} +56 -56
  11. package/dist/cli-bundle/chunks/{chunk-FOTXRNY6.js → chunk-4SLLCDFL.js} +39 -39
  12. package/dist/cli-bundle/chunks/{chunk-GRWPZR7F.js → chunk-4UPZLUT2.js} +7 -7
  13. package/dist/cli-bundle/chunks/{chunk-U55RYT3I.js → chunk-6OJVQ7SW.js} +2 -2
  14. package/dist/cli-bundle/chunks/{chunk-TYJXMT3Q.js → chunk-7TAGYNFP.js} +2 -2
  15. package/dist/cli-bundle/chunks/{chunk-QQD3VRMZ.js → chunk-AUS6USO4.js} +2 -2
  16. package/dist/cli-bundle/chunks/{chunk-4ODHIX7N.js → chunk-IEP3VAT5.js} +2 -2
  17. package/dist/cli-bundle/chunks/{chunk-HTHTX6E6.js → chunk-JX6WCCHL.js} +2 -2
  18. package/dist/cli-bundle/chunks/chunk-LC6WEA5U.js +2 -0
  19. package/dist/cli-bundle/chunks/{chunk-VMO4P5MX.js → chunk-LKGQUZ5M.js} +2 -2
  20. package/dist/cli-bundle/chunks/{chunk-TC74K7SS.js → chunk-OKVDVERQ.js} +2 -2
  21. package/dist/cli-bundle/chunks/{chunk-SZQCHJI4.js → chunk-TSF2LPIH.js} +2 -2
  22. package/dist/cli-bundle/chunks/{chunk-MJWKR7YA.js → chunk-V5UGBYHN.js} +3 -3
  23. package/dist/cli-bundle/chunks/{register-list-query-426QTRET.js → register-list-query-6PAJ4PBU.js} +2 -2
  24. package/dist/cli-bundle/chunks/{register-mutation-FLI3HHMP.js → register-mutation-RZCXZXYS.js} +2 -2
  25. package/dist/cli-bundle/chunks/{register-operations-TP7ZG4MK.js → register-operations-GK6VU2H2.js} +2 -2
  26. package/dist/cli-bundle/chunks/register-setup-ASEMNMBF.js +2 -0
  27. package/dist/cli-bundle/focused-chunks/{chunk-H3BI4EDO.js → chunk-6J2YCGSN.js} +3 -3
  28. package/dist/cli-bundle/focused-chunks/{chunk-XKH2FC5D.js → chunk-6UNKK3UH.js} +2 -2
  29. package/dist/cli-bundle/focused-chunks/{chunk-NRHTXBTI.js → chunk-DQ3MB7BO.js} +2 -2
  30. package/dist/cli-bundle/focused-chunks/{chunk-PMPFLA6X.js → chunk-E7LYK7V5.js} +2 -2
  31. package/dist/cli-bundle/focused-chunks/{chunk-25BBHWMH.js → chunk-GZD4ZYIB.js} +2 -2
  32. package/dist/cli-bundle/focused-chunks/chunk-KMPKKSA6.js +2 -0
  33. package/dist/cli-bundle/focused-chunks/{chunk-TLF6N56J.js → chunk-LBDWUHQD.js} +2 -2
  34. package/dist/cli-bundle/focused-chunks/{chunk-UIFVIE5F.js → chunk-MILJCOFJ.js} +2 -2
  35. package/dist/cli-bundle/focused-chunks/{chunk-MK5AKKHK.js → chunk-NETVXIH5.js} +2 -2
  36. package/dist/cli-bundle/focused-chunks/{chunk-Q355NPLH.js → chunk-NWRVNHAD.js} +2 -2
  37. package/dist/cli-bundle/focused-chunks/{chunk-XVBWZTU2.js → chunk-NZAG7OKB.js} +12 -12
  38. package/dist/cli-bundle/focused-chunks/{chunk-OY3VHCTX.js → chunk-OJKJFDIG.js} +2 -2
  39. package/dist/cli-bundle/focused-chunks/chunk-OJRX6G22.js +2 -0
  40. package/dist/cli-bundle/focused-chunks/{chunk-NVVB2HJC.js → chunk-PDVL7QYU.js} +16 -16
  41. package/dist/cli-bundle/focused-chunks/{chunk-O7MIBEMK.js → chunk-QO4MTAEA.js} +2 -2
  42. package/dist/cli-bundle/focused-chunks/{chunk-ABA3KRPY.js → chunk-SMADBUPL.js} +2 -2
  43. package/dist/cli-bundle/main.js +21 -21
  44. package/dist/cli-bundle/sdk-authoring.js +1 -1
  45. package/dist/cli-bundle/sdk-contracts.js +1 -1
  46. package/dist/cli-bundle/sdk-core.js +2 -2
  47. package/dist/cli-bundle/sdk-governance.js +1 -1
  48. package/dist/cli-bundle/sdk-graph.js +1 -1
  49. package/dist/cli-bundle/sdk-merge.js +23 -23
  50. package/dist/cli-bundle/sdk-query.js +1 -1
  51. package/dist/cli-bundle/sdk-runtime.js +1 -1
  52. package/dist/cli-bundle/sdk-testing.js +1 -1
  53. package/dist/cli-bundle/sdk.js +8 -8
  54. package/dist/sdk/agent-capability-contracts.js +1 -1
  55. package/dist/sdk/cli-contracts/command-aliases.js +1 -1
  56. package/dist/sdk/cli-contracts/grammar-contracts.js +1 -1
  57. package/dist/sdk/completion/shared.d.ts +1 -1
  58. package/dist/sdk/completion/shared.js +1 -1
  59. package/dist/sdk/extension/static-inventory.d.ts +54 -0
  60. package/dist/sdk/extension/static-inventory.js +2 -0
  61. package/dist/sdk/generated/generated-error-code-catalog-part-1.js +1 -1
  62. package/dist/sdk/generated/generated-error-code-catalog-part-2.js +1 -1
  63. package/dist/sdk/guide-topics.js +1 -1
  64. package/dist/sdk/index.d.ts +1 -0
  65. package/dist/sdk/index.js +1 -1
  66. package/dist/sdk/public-surface.json +1 -1
  67. package/dist/sdk/query/complete-list.js +1 -1
  68. package/dist/sdk/read-output/provenance.d.ts +20 -0
  69. package/dist/sdk/read-output/provenance.js +2 -0
  70. package/dist/sdk/read-output-contracts.js +1 -1
  71. package/dist/sdk/runtime-input.js +1 -1
  72. package/docs/CLI_GRAMMAR.md +31 -0
  73. package/docs/CODEX_PLUGIN.md +8 -0
  74. package/docs/EXTENSION_LIFECYCLE.md +18 -0
  75. package/docs/RELEASING.md +46 -1
  76. package/docs/agent-task-token-baseline.json +4 -4
  77. package/docs/generated/AGENT_CAPABILITY_ROUTING.md +1 -1
  78. package/docs/generated/AGENT_COMMAND_SURFACE.md +5 -1
  79. package/docs/generated/FLAG_LEXICON_BUDGETS.md +4 -0
  80. package/docs/generated/REFUSAL_CLOSURE_CENSUS.md +14 -7
  81. package/marketplace.json +2 -2
  82. package/package.json +2 -2
  83. package/packages/pm-beads/package.json +1 -1
  84. package/packages/pm-calendar/package.json +1 -1
  85. package/packages/pm-command-kit/package.json +1 -1
  86. package/packages/pm-digital-twin/package.json +1 -1
  87. package/packages/pm-governance-audit/package.json +1 -1
  88. package/packages/pm-guide-shell/package.json +1 -1
  89. package/packages/pm-kanban/package.json +1 -1
  90. package/packages/pm-lifecycle-hooks/package.json +1 -1
  91. package/packages/pm-linked-test-adapters/package.json +1 -1
  92. package/packages/pm-search-advanced/package.json +1 -1
  93. package/packages/pm-templates/package.json +1 -1
  94. package/packages/pm-todos/package.json +1 -1
  95. package/packages/pm-vcs/package.json +1 -1
  96. package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
  97. package/plugins/pm-claude/README.md +5 -1
  98. package/plugins/pm-claude/package.json +2 -2
  99. package/plugins/pm-claude/skills/pm-audit/SKILL.md +14 -103
  100. package/plugins/pm-claude/skills/pm-audit/agents/openai.yaml +4 -0
  101. package/plugins/pm-claude/skills/pm-developer/SKILL.md +20 -143
  102. package/plugins/pm-claude/skills/pm-developer/agents/openai.yaml +4 -0
  103. package/plugins/pm-claude/skills/pm-planner/SKILL.md +16 -167
  104. package/plugins/pm-claude/skills/pm-planner/agents/openai.yaml +4 -0
  105. package/plugins/pm-claude/skills/pm-release/SKILL.md +18 -102
  106. package/plugins/pm-claude/skills/pm-release/agents/openai.yaml +4 -0
  107. package/plugins/pm-claude/skills/pm-workflow/SKILL.md +25 -156
  108. package/plugins/pm-claude/skills/pm-workflow/agents/openai.yaml +4 -0
  109. package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
  110. package/plugins/pm-codex/README.md +10 -2
  111. package/plugins/pm-codex/mcp.json +11 -0
  112. package/plugins/pm-codex/package.json +2 -2
  113. package/plugins/pm-codex/plugin.json +45 -0
  114. package/plugins/pm-codex/skills/pm-audit/SKILL.md +21 -0
  115. package/plugins/pm-codex/skills/pm-audit/agents/openai.yaml +4 -0
  116. package/plugins/pm-codex/skills/pm-auditor/SKILL.md +5 -40
  117. package/plugins/pm-codex/skills/pm-auditor/agents/openai.yaml +3 -5
  118. package/plugins/pm-codex/skills/pm-developer/SKILL.md +26 -0
  119. package/plugins/pm-codex/skills/pm-developer/agents/openai.yaml +4 -0
  120. package/plugins/pm-codex/skills/pm-native/SKILL.md +7 -87
  121. package/plugins/pm-codex/skills/pm-native/agents/openai.yaml +3 -5
  122. package/plugins/pm-codex/skills/pm-planner/SKILL.md +22 -0
  123. package/plugins/pm-codex/skills/pm-planner/agents/openai.yaml +4 -0
  124. package/plugins/pm-codex/skills/pm-release/SKILL.md +17 -38
  125. package/plugins/pm-codex/skills/pm-release/agents/openai.yaml +2 -4
  126. package/plugins/pm-codex/skills/pm-workflow/SKILL.md +39 -0
  127. package/plugins/pm-codex/skills/pm-workflow/agents/openai.yaml +4 -0
  128. package/dist/cli-bundle/chunks/register-setup-574SIVQZ.js +0 -2
  129. package/dist/cli-bundle/focused-chunks/chunk-HNHMK5JI.js +0 -2
  130. package/dist/cli-bundle/focused-chunks/chunk-HQPTDJLF.js +0 -2
@@ -0,0 +1,21 @@
1
+ ---
2
+ name: pm-audit
3
+ description: Use when asked to inspect pm tracker health, duplicate work, graph quality, privacy, or release readiness. Report verified findings and reuse existing lineage.
4
+ license: MIT
5
+ ---
6
+
7
+ # pm Review
8
+
9
+ Read the requested scope and the full live records behind any status claim.
10
+ Use pm_health, pm_validate, pm_search, pm_graph, and pm_contracts as needed.
11
+ Use pm_run for duplicate checks when no narrow tool covers them. Check omission
12
+ receipts and follow cursors before reporting totals.
13
+
14
+ Classify each finding by its observable impact. Search all statuses before
15
+ filing it and link it to its source with a meaningful typed relationship.
16
+ Record exact commands and results on the canonical item. Keep credentials,
17
+ private operational data, and raw meeting content out of public records.
18
+
19
+ An inspection does not imply permission to rewrite history or fabricate
20
+ relationships. When asked to fix findings, claim only the work being changed
21
+ and follow the pm-developer skill.
@@ -0,0 +1,4 @@
1
+ interface:
2
+ display_name: "pm Review"
3
+ short_description: "Inspect tracker health and readiness"
4
+ default_prompt: "Review live pm health, quality, and release evidence; report verified findings."
@@ -1,46 +1,11 @@
1
1
  ---
2
2
  name: pm-auditor
3
- description: Audit pm-cli repositories with native pm MCP tools, preserving duplicate checks, privacy boundaries, linked evidence, and verification records.
3
+ description: Use only when an existing Codex workflow explicitly invokes pm-auditor. This compatibility skill routes to the canonical pm-audit review skill.
4
4
  license: MIT
5
5
  ---
6
6
 
7
- # pm Auditor
7
+ # pm Auditor Compatibility
8
8
 
9
- Use for broad repository audits, release readiness checks, privacy reviews, and agent-workflow health checks.
10
-
11
- ## Audit Flow
12
-
13
- 1. Use `pm_context` with standard or deep options.
14
- 2. Use `pm_search` for likely existing audit or release items.
15
- 4. Convert each actionable finding into a pm item or append evidence to an existing item.
16
- 5. Keep sensitive operational data out of public docs and tracked comments.
17
-
18
- ## Evidence
19
-
20
- Record exact verification commands and summarized results through `pm_comments`, and link touched files through `pm_files`.
21
-
22
- ## Progressive Disclosure and Token Discipline
23
-
24
- Load the smallest thing that answers the question. Costs are measured.
25
-
26
- | Need | Call | Cost |
27
- |------|------|------|
28
- | Pick or resume work | `pm_next`, or `pm_context` with `limit: 10` | ~2.1-2.5k tok |
29
- | Exact flags for one command | `pm_contracts` with `command: "<name>", flagsOnly: true` | ~1-3.4k tok |
30
- | The whole command surface with per-command ceilings | `pm_contracts` with `summary: true` | ~2.6k tok |
31
- | An unfamiliar capability family | `pm_run` with `action: "guide", topic: "<topic>", depth: "brief"` | ~0.6-1k tok |
32
-
33
- Guide topics are declared at runtime: `pm guide` prints the current index and
34
- `pm guide <topic> --depth brief` expands one topic. Do not copy the list.
35
-
36
- Never load `docs/COMMANDS.md` (~29k tok) or `docs/SDK.md` (~45k tok) whole.
37
-
38
- Bound every read in this order: projection (`outputInclude`), then row limit
39
- (`outputLimit` or `limit`), then `outputBudget`, then `outputCursor` to resume.
40
- Read the `omission_receipt` before treating a result as complete — a
41
- budget-truncated read is a claim about the part it withheld, and a truncated
42
- list must never be summarized as if it were the whole population.
43
-
44
- Author identity is detected automatically. Never pass `author` and never set
45
- `PM_AUTHOR`; the harness, model, effort, role, and topic are probed and recorded
46
- on every history entry.
9
+ Use pm-audit for live tracker health, duplicate, graph, privacy, and release
10
+ readiness reviews. Read full records and omission receipts before making a
11
+ status claim. Reuse existing lineage for each verified finding.
@@ -1,6 +1,4 @@
1
1
  interface:
2
- display_name: "pm Auditor"
3
- short_description: "Audit pm health, contracts, privacy, and readiness"
4
- icon_small: "./assets/pm-cli-small.svg"
5
- icon_large: "./assets/pm-cli-small.svg"
6
- default_prompt: "Audit this pm repository with native pm tools, dedupe findings, link evidence, and avoid leaking private data."
2
+ display_name: "pm Auditor Compatibility"
3
+ short_description: "Route older reviews to the current pm review skill"
4
+ default_prompt: "Review this tracker using the canonical pm-audit guidance."
@@ -0,0 +1,26 @@
1
+ ---
2
+ name: pm-developer
3
+ description: Use when implementing, debugging, refactoring, or shipping code, tests, or docs tracked by pm. Keep SDK behavior and verification linked to the active item.
4
+ license: MIT
5
+ ---
6
+
7
+ # pm Developer
8
+
9
+ Orient with pm-workflow before editing. Claim the canonical item and keep its
10
+ scope aligned with the change.
11
+
12
+ 1. Read the complete source owner and relevant tests before editing. For a
13
+ regression, identify the observable contract and the change that would
14
+ make its test fail.
15
+ 2. Put domain behavior in the public pm SDK. Keep CLI and MCP adapters thin,
16
+ with transport-specific tests only where those boundaries add risk.
17
+ 3. Link changed files, docs, and isolated runnable tests through pm_files,
18
+ pm_docs, and pm_test.
19
+ 4. Run the focused test, build, full coverage, static quality, and installed
20
+ consumer checks required by the affected contract. Keep tracker test roots
21
+ separate from the real repository.
22
+ 5. Record exact results in pm_comments. Close with structured resolution,
23
+ expected, and actual fields only when the criteria are actually met.
24
+
25
+ Prefer pm_contracts for flags and the SDK public surface for integration APIs.
26
+ An unknown review provider or missing check is not approval.
@@ -0,0 +1,4 @@
1
+ interface:
2
+ display_name: "pm Developer"
3
+ short_description: "Deliver code with linked pm evidence"
4
+ default_prompt: "Use pm to claim, implement, verify, document, and close this repository change."
@@ -1,94 +1,14 @@
1
1
  ---
2
2
  name: pm-native
3
- description: Use pm-cli natively in Codex through bundled MCP tools for planning, tracking, mutation, validation, and reporting without invoking the pm shell command.
3
+ description: Use only when an existing Codex workflow explicitly invokes pm-native. This compatibility skill routes to the canonical pm-workflow and pm-planner skills.
4
4
  license: MIT
5
5
  ---
6
6
 
7
- # pm Native Workflow
7
+ # pm Native Compatibility
8
8
 
9
- Use this skill whenever a Codex task should be tracked through pm.
9
+ Use pm-workflow for orientation, claim, evidence, and handoff. Use pm-planner
10
+ for durable Plan steps. The native pm MCP server exposes the same public SDK
11
+ contracts in both workflows.
10
12
 
11
- ## Tool Preference
12
-
13
- Use MCP tools before shell commands:
14
-
15
- - Orient: `pm_context`, `pm_search`, `pm_list`, `pm_get`
16
- - Mutate: `pm_create`, `pm_update`, `pm_claim`, `pm_release`, `pm_close`
17
- - Evidence: `pm_comments`, `pm_notes`, `pm_learnings`, `pm_files`, `pm_docs`, `pm_test`
18
- - Verify: `pm_validate`, `pm_health`, `pm_contracts`
19
- - Everything else: `pm_run` with an explicit `action`
20
-
21
- Do not pass `path` during real repository work. For tests, pass a sandbox `cwd` or `path`.
22
-
23
- ## Required Loop
24
-
25
- 1. Run `pm_context`, `pm_search`, and `pm_list` before creating work.
26
- 2. Reuse an existing item when one matches.
27
- 3. Claim the item with `pm_claim`.
28
- 4. Link changed files/docs/tests as work proceeds.
29
- 5. Add concise evidence with `pm_comments`.
30
- 6. Run linked and project verification.
31
- 7. Close with `pm_close` and release with `pm_release`.
32
-
33
- ## Native Argument Shape
34
-
35
- Most tools accept:
36
-
37
- ```json
38
- {
39
- "cwd": "/repo/root",
40
- "options": {
41
- "limit": "10"
42
- }
43
- }
44
- ```
45
-
46
- `pm_run` accepts an `action` plus `options`:
47
-
48
- ```json
49
- {
50
- "action": "calendar",
51
- "options": {
52
- "view": "week",
53
- "format": "markdown"
54
- }
55
- }
56
- ```
57
-
58
- ## Plan workflow (`pm_plan`)
59
-
60
- Codex-style living ExecPlans are first-class via the `Plan` item type and the `pm_plan` MCP tool. Use [Command Reference: Plan Workflow](../../../../docs/COMMANDS.md#plan-workflow) as the canonical lifecycle recipe; this skill keeps only Codex-specific routing notes.
61
-
62
- Use `pm_plan` for plan-then-execute workflows; use `pm_create` with type Task/Feature/Epic for already-decomposed backlog work.
63
-
64
- Invariants:
65
-
66
- - One step `in_progress` at a time by default; pass `allowMultipleActive: true` for explicit parallel branches.
67
- - Use `subcommand: block-step` with `stepBlockedReason` when discovery flips a step.
68
- - Use `subcommand: materialize` once steps are concrete enough to become Tasks.
69
-
70
- ## Progressive Disclosure and Token Discipline
71
-
72
- Load the smallest thing that answers the question. Costs are measured.
73
-
74
- | Need | Call | Cost |
75
- |------|------|------|
76
- | Pick or resume work | `pm_next`, or `pm_context` with `limit: 10` | ~2.1-2.5k tok |
77
- | Exact flags for one command | `pm_contracts` with `command: "<name>", flagsOnly: true` | ~1-3.4k tok |
78
- | The whole command surface with per-command ceilings | `pm_contracts` with `summary: true` | ~2.6k tok |
79
- | An unfamiliar capability family | `pm_run` with `action: "guide", topic: "<topic>", depth: "brief"` | ~0.6-1k tok |
80
-
81
- Guide topics are declared at runtime: `pm guide` prints the current index and
82
- `pm guide <topic> --depth brief` expands one topic. Do not copy the list.
83
-
84
- Never load `docs/COMMANDS.md` (~29k tok) or `docs/SDK.md` (~45k tok) whole.
85
-
86
- Bound every read in this order: projection (`outputInclude`), then row limit
87
- (`outputLimit` or `limit`), then `outputBudget`, then `outputCursor` to resume.
88
- Read the `omission_receipt` before treating a result as complete — a
89
- budget-truncated read is a claim about the part it withheld, and a truncated
90
- list must never be summarized as if it were the whole population.
91
-
92
- Author identity is detected automatically. Never pass `author` and never set
93
- `PM_AUTHOR`; the harness, model, effort, role, and topic are probed and recorded
94
- on every history entry.
13
+ Read live pm_context and pm_search before creating or mutating items. Claim
14
+ only active work, preserve linked evidence, and release the claim when done.
@@ -1,6 +1,4 @@
1
1
  interface:
2
- display_name: "pm Native"
3
- short_description: "Track Codex work through native pm MCP tools"
4
- icon_small: "./assets/pm-cli-small.svg"
5
- icon_large: "./assets/pm-cli-small.svg"
6
- default_prompt: "Use native pm tools to orient, claim, implement, verify, and close this task without shelling out to pm."
2
+ display_name: "pm Native Compatibility"
3
+ short_description: "Route older Codex workflows to current pm skills"
4
+ default_prompt: "Continue this older pm-native workflow with the canonical pm-workflow and pm-planner guidance."
@@ -0,0 +1,22 @@
1
+ ---
2
+ name: pm-planner
3
+ description: Use when triaging requests, organizing a backlog, decomposing an epic, or making a durable pm plan. Search all statuses and build evidence-backed typed relationships.
4
+ license: MIT
5
+ ---
6
+
7
+ # pm Planner
8
+
9
+ 1. Read pm_context and the relevant parent or outcome milestone.
10
+ 2. Search all statuses and inspect nearest matches before creating anything.
11
+ 3. Use a Plan when ordered steps, decisions, discoveries, and handoff must
12
+ remain resumable. Use Epic, Feature, Task, Issue, and Decision items for
13
+ durable backlog work with different ownership.
14
+ 4. Give new work a parent, testable acceptance criteria, expected result, and
15
+ a create-time duplicate-check explanation.
16
+ 5. Add typed edges only when evidence supports their meaning. Use dependency
17
+ edges for ordering and verification edges for proof; do not invent graph
18
+ depth or fill the graph with related edges.
19
+ 6. Validate the resulting tracker and summarize the next actionable items.
20
+
21
+ Use pm_plan for a living plan and pm_contracts to discover exact options.
22
+ Keep one plan step in progress unless parallel work is explicitly intended.
@@ -0,0 +1,4 @@
1
+ interface:
2
+ display_name: "pm Planner"
3
+ short_description: "Plan and connect project work"
4
+ default_prompt: "Use pm to deduplicate this request, plan its work, and link it to the project outcome."
@@ -1,45 +1,24 @@
1
1
  ---
2
2
  name: pm-release
3
- description: Run compatibility-gated pm-cli release workflows with native pm tools, linked evidence, and public-surface verification.
3
+ description: Use when preparing a pm release, reviewing its gates, publishing, or verifying the released artifact. Keep source, reviewed head, main, tag, registry, and telemetry evidence distinct.
4
4
  license: MIT
5
5
  ---
6
6
 
7
7
  # pm Release
8
8
 
9
- Use for release prep, compatibility gates, publication checks, and post-release verification.
10
-
11
- ## Release Loop
12
-
13
- 1. Find or create the release item after duplicate checks.
14
- 2. Claim it and link release docs, changelog, compatibility scripts, and tests.
15
- 3. Run sandboxed compatibility checks before changing release assets.
16
- 4. Run full local gates before tagging or publishing.
17
- 5. Verify public surfaces after publish and record results through `pm_comments`.
18
-
19
- Use `pm_run` for release-adjacent pm actions not exposed as narrow tools.
20
-
21
- ## Progressive Disclosure and Token Discipline
22
-
23
- Load the smallest thing that answers the question. Costs are measured.
24
-
25
- | Need | Call | Cost |
26
- |------|------|------|
27
- | Pick or resume work | `pm_next`, or `pm_context` with `limit: 10` | ~2.1-2.5k tok |
28
- | Exact flags for one command | `pm_contracts` with `command: "<name>", flagsOnly: true` | ~1-3.4k tok |
29
- | The whole command surface with per-command ceilings | `pm_contracts` with `summary: true` | ~2.6k tok |
30
- | An unfamiliar capability family | `pm_run` with `action: "guide", topic: "<topic>", depth: "brief"` | ~0.6-1k tok |
31
-
32
- Guide topics are declared at runtime: `pm guide` prints the current index and
33
- `pm guide <topic> --depth brief` expands one topic. Do not copy the list.
34
-
35
- Never load `docs/COMMANDS.md` (~29k tok) or `docs/SDK.md` (~45k tok) whole.
36
-
37
- Bound every read in this order: projection (`outputInclude`), then row limit
38
- (`outputLimit` or `limit`), then `outputBudget`, then `outputCursor` to resume.
39
- Read the `omission_receipt` before treating a result as complete — a
40
- budget-truncated read is a claim about the part it withheld, and a truncated
41
- list must never be summarized as if it were the whole population.
42
-
43
- Author identity is detected automatically. Never pass `author` and never set
44
- `PM_AUTHOR`; the harness, model, effort, role, and topic are probed and recorded
45
- on every history entry.
9
+ Inspect the release item and current release position before mutation. Search
10
+ for an existing release or incident lineage and reuse it.
11
+
12
+ 1. Link the changed files, changelog, compatibility evidence, and release
13
+ tests to the item that owns them.
14
+ 2. Run the build, full coverage, static quality, security, docs, package,
15
+ version, and hosted analysis gates required by the repository.
16
+ 3. Verify the exact reviewed PR head and resolve actionable feedback before
17
+ merging. A silent or quota-limited provider is unavailable evidence.
18
+ 4. After publishing, verify the main commit, tag, GitHub Release, npm
19
+ package, installed npm and Bun consumers, Sentry, and telemetry separately.
20
+ 5. Record immutable close evidence and release the claim.
21
+
22
+ Use the repository release pipeline and pm_contracts rather than a remembered
23
+ flag spelling. Never assume a successful API request proves a scheduled
24
+ release or physical telemetry delivery.
@@ -1,6 +1,4 @@
1
1
  interface:
2
2
  display_name: "pm Release"
3
- short_description: "Run pm release workflows with linked evidence"
4
- icon_small: "./assets/pm-cli-small.svg"
5
- icon_large: "./assets/pm-cli-small.svg"
6
- default_prompt: "Use native pm tools to prepare, gate, publish-check, and document this pm-cli release."
3
+ short_description: "Verify release gates and artifacts"
4
+ default_prompt: "Use pm to prepare, gate, and verify this release with distinct source and published evidence."
@@ -0,0 +1,39 @@
1
+ ---
2
+ name: pm-workflow
3
+ description: Use when starting, resuming, or handing off work in a repository managed by pm. Orient from live context, reuse existing items, and leave evidence for the next agent.
4
+ license: MIT
5
+ ---
6
+
7
+ # pm Workflow
8
+
9
+ Project management is context management. Read the live tracker before describing
10
+ work as open, blocked, or done. Use the bundled pm MCP tools when available;
11
+ use the pm CLI with the same contracts when they are not.
12
+
13
+ ## Orient
14
+
15
+ 1. Read pm_context with a bounded limit, then pm_list for open and in-progress work.
16
+ 2. Search all statuses before creating an item. Inspect the candidate's full
17
+ metadata, comments, notes, learnings, dependencies, and history.
18
+ 3. Follow omission receipts and cursors before making a completeness claim.
19
+ 4. Cross-check release, CI, package, or infrastructure claims against the live
20
+ system that owns them.
21
+
22
+ ## Work and hand off
23
+
24
+ Claim only an item being actively edited. Link files, docs, tests, and typed
25
+ relationships that express a real dependency or outcome. Record concise
26
+ evidence, then close with resolution, expected, and actual results when the
27
+ acceptance criteria are met. Release the claim when stopping.
28
+
29
+ For handoff, report the item IDs, exact current status, last verified result,
30
+ remaining work, and the next read command. Do not copy the entire tracker.
31
+
32
+ ## Host adapters
33
+
34
+ In Claude Code, mirror a claimed item in the task panel when TaskCreate and
35
+ TaskUpdate are available. Keep pm as the durable source of truth. In Codex,
36
+ use the native MCP tools and the same claim, evidence, close, and release loop.
37
+
38
+ Use pm_contracts for exact active flags and pm_run for actions without a narrow
39
+ tool. Never set a static author; let the host identity be detected.
@@ -0,0 +1,4 @@
1
+ interface:
2
+ display_name: "pm Workflow"
3
+ short_description: "Orient and hand off tracked project work"
4
+ default_prompt: "Use pm to read live context, select existing work, and leave a concise evidence-backed handoff."
@@ -1,2 +0,0 @@
1
- import{g as j,i as P}from"./chunk-SZQCHJI4.js";import{La as U,Oa as O,Xa as I,ab as L,cb as T}from"./chunk-MJWKR7YA.js";import"./chunk-DEZPZOQ7.js";import{Ef as S,Fo as y,Hf as w,If as h,Io as k,_a as D,ki as R,l as G,la as d,m as $,na as m}from"./chunk-IYN4MJ2C.js";import C from"node:fs/promises";import W from"node:path";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="26ea7f42-d5f7-5ada-afd9-389dadc4d138")}catch{}})();(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="0b0e08e0-f6e7-59c4-ac96-9f47b172727a")}catch{}})();(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="d975120a-964e-5b19-ae10-8ba011ba9bf8")}catch{}})();(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="108609fa-51fc-5bd0-ac54-de2ad14a66c6")}catch{}})();(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="b36466e6-5574-5509-909a-e8599f11664c")}catch{}})();(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="e5e1e242-6864-5a72-adb9-0eda4c65a0c3")}catch{}})();(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="b04d19bc-04b2-54e4-af48-5f930e1167dd")}catch{}})();var H={extension:"extension",package:void 0};async function _(e,t){if(!e)return;let o=G(e),a=y(t);await R(D(process.cwd(),a.path)).then(r=>r.ux.deprecation_hints)&&h($(o))}var V={init:"init",install:"install",uninstall:"uninstall",explore:"explore",manage:"manage",describe:"describe",reload:"reload",doctor:"doctor",catalog:"catalog",adopt:"adopt","adopt-all":"adoptAll",activate:"activate",deactivate:"deactivate",migrate:"migrate"};function X(e){let t=e.capability,o=typeof t=="string"?[t]:Array.isArray(t)?t.filter(i=>typeof i=="string"):[],a=[...new Set(o.map(i=>i.trim().toLowerCase()).filter(i=>i.length>0))];if(a.length>1)throw new m(`Multiple scaffold capabilities cannot be combined yet: ${a.join(", ")}. Choose one capability per scaffold.`,d.USAGE);return a[0]}function A(e,t,o="extension"){let a={...e};t!==void 0&&(a[V[t]]=!0);let i=(...c)=>c.some(s=>a[s]===!0),r=(...c)=>{for(let s of c)if(typeof a[s]=="string")return a[s]};return{init:i("init"),scaffold:i("scaffold"),install:i("install"),uninstall:i("uninstall"),explore:i("explore","list"),manage:i("manage"),describe:i("describe"),markdown:i("markdown"),reload:i("reload"),doctor:i("doctor"),catalog:i("catalog"),adopt:i("adopt"),adoptAll:i("adoptAll","adopt_all","adopt-all"),activate:i("activate"),deactivate:i("deactivate"),migrate:i("migrate"),project:i("project"),local:i("local"),global:i("global"),gh:r("gh"),github:r("github"),ref:r("ref"),capability:X(e),declarative:i("declarative"),fields:r("fields"),detail:r("detail"),output:r("output"),trace:i("trace"),watch:i("watch"),runtimeProbe:i("runtimeProbe","runtime_probe","runtime-probe"),fixManagedState:i("fixManagedState","fix_managed_state","fix-managed-state"),isolated:i("isolated"),ignoreGlobal:i("ignoreGlobal","ignore_global","ignore-global"),strictExit:i("strictExit","strict_exit","strict-exit"),failOnWarn:i("failOnWarn","fail_on_warn","fail-on-warn"),dryRun:i("dryRun","dry_run","dry-run"),vocabulary:o}}async function Y(e){let t=(await C.readdir(process.cwd())).filter(a=>!a.startsWith(".")).sort((a,i)=>a.localeCompare(i)),o=[...e].sort((a,i)=>a.localeCompare(i));return t.length===o.length&&t.every((a,i)=>a===o[i])}async function J(e){let t=(e??[]).map(o=>o.trim()).filter(o=>o.length>0);return t.length<=1?t.length===0?void 0:t:await Y(t)?["*"]:t}function M(e,t,o){let a=e.markdown===!0;if(o!==void 0&&o==="")throw new m("--output requires a non-empty file path.",d.USAGE);if(o!==void 0&&!a)throw new m("--output is only supported with --markdown describe output.",d.USAGE);if(a){if(t.json)throw new m("Cannot combine --json with --markdown.",d.USAGE);if(e.describe!==!0)throw new m("--markdown is only supported by the describe action.",d.USAGE)}}async function Q(e){let t=O(e.result.details,e.vocabulary);if(e.outputPath!==void 0){let o=W.resolve(e.outputPath);await C.mkdir(W.dirname(o),{recursive:!0}),await C.writeFile(o,t,"utf8")}if(!e.globalOptions.quiet){for(let o of e.result.warnings)h(`warning: ${o}`);e.outputPath===void 0&&S(t)}}function Z(e,t){let o=!!t.strictExit||!!t.failOnWarn;if(e.action!=="doctor"||!o)return;let a=e.details!==null&&typeof e.details=="object"?e.details:{},i=a.summary!==null&&typeof a.summary=="object"?a.summary:null,r=i&&typeof i.status=="string"?i.status:void 0;(e.warnings.length>0||r!==void 0&&r!=="ok")&&(process.exitCode=d.GENERIC_FAILURE)}async function p(e,t,o,a,i="extension"){let r=y(o),c=Date.now(),s=i==="extension"?"package":i;await _(H[i],o);let n=A(t,a,s),f=(typeof n.output=="string"?n.output:void 0)?.trim();M(n,r,f);let g=await I(e,n,r);n.markdown===!0?await Q({result:g,vocabulary:s,outputPath:f,globalOptions:r}):w(g,r),Z(g,n),g.ok===!1&&(process.exitCode=d.GENERIC_FAILURE),r.profile&&h(`profile:command=extension took_ms=${Date.now()-c}`)}function ee(e){return e.details!==null&&typeof e.details=="object"?e.details:{}}function te(e){return e instanceof m?{message:e.message,exit_code:e.exitCode,...e.context}:{message:e instanceof Error?e.message:String(e),exit_code:d.GENERIC_FAILURE}}async function oe(e,t,o){let a=[],i=[],r=d.GENERIC_FAILURE;for(let c of e)try{let s=await I(c,t,o),n=ee(s),l=Array.isArray(s.warnings)?s.warnings:[];i.push(...l);let f=s.ok===!0;a.push({target:c,ok:f,extension:n.extension,source:n.source,install_plan:n.install_plan,dry_run:n.dry_run,destination_path:n.destination_path,activated:n.activated,settings_changed:n.settings_changed,command_paths:n.command_paths,action_paths:n.action_paths,runtime_activation_status:n.runtime_activation_status,activation_diagnostics:n.activation_diagnostics,command_discovery:n.command_discovery,verification:n.verification,warnings:l,...f?{}:{error:{message:"Extension install returned ok=false without throwing an error.",exit_code:d.GENERIC_FAILURE,code:"extension_install_soft_failed"}}})}catch(s){let n=te(s),l=n.exit_code;typeof l=="number"&&r===d.GENERIC_FAILURE&&l!==d.GENERIC_FAILURE&&(r=l),a.push({target:c,ok:!1,error:n})}return{rows:a,warnings:i,failureExitCode:r}}async function z(e,t,o,a){let i=a==="extension"?"package":a;await _(H[a],o);let r=await J(e);if(r===void 0||r.length<=1){await p(r?.[0],t,o,"install",i);return}let c=y(o),s=Date.now(),n=A(t,"install",i);if(M(n,c,void 0),[n.gh,n.github].some(b=>typeof b=="string"&&b.trim().length>0))throw new m("Multiple install targets cannot be combined with --gh/--github. Install one GitHub source per command, or pass multiple explicit local, bundled, or npm: targets.",d.USAGE,{code:"multi_target_github_install_ambiguous",required:"Use exactly one positional target with --gh/--github, or omit --gh/--github when installing multiple targets.",examples:["pm install --gh owner/repo","pm install npm:pm-guide-shell pm-todos"]});let{rows:f,warnings:g,failureExitCode:E}=await oe(r,n,c),v=f.filter(b=>b.ok!==!0).length,K={ok:v===0,action:"install",scope:n.global===!0?"global":"project",installed_count:n.dryRun===!0?0:f.length-v,...n.dryRun===!0?{dry_run:!0,planned_count:f.length-v}:{},failed_count:v,targets:f,warnings:[...new Set(g)].sort((b,B)=>b.localeCompare(B))};w(K,c),v>0&&(process.exitCode=E),c.profile&&h(`profile:command=extension took_ms=${Date.now()-s}`)}function ae(e){return e.option("--project","Use project extension scope (default)").option("--local","Alias for --project").option("--global","Use global extension scope")}function x(e){return e.option("--project","Use project package scope (default)").option("--local","Alias for --project").option("--global","Use global package scope")}function u(e,t){return t==="package"?x(e):ae(e)}function N(e){return e.option("--dry-run","Plan CLI/package upgrades without running npm or reinstalling packages").option("--cli-only","Upgrade only the pm CLI/SDK npm package").option("--packages-only","Upgrade only managed pm packages").option("--repair","Force npm global reinstall when upgrading the pm CLI/SDK").option("--tag <value>","npm dist-tag/version for CLI and registry package upgrades").option("--package-name <value>","Override the CLI package name for self-upgrade testing")}async function q(e,t,o){let a=y(t),i=Date.now();o&&await _("upgrade",t);let r=await P(e,t.optsWithGlobals(),a);w(r,a),r.ok||(process.exitCode=d.GENERIC_FAILURE),a.profile&&h(`profile:command=package-upgrade took_ms=${Date.now()-i}`)}function F(e,t){let o=t==="package"?"package":"extension",a=t==="package"?"packages":"extensions",i=t,r=e.command(i,{hidden:t==="extension"}).argument("[target]",`${o[0].toUpperCase()}${o.slice(1)} source, name, or scaffold path`).option("--init",`Generate a starter ${o} scaffold at target path`).option("--scaffold","Alias for --init").option("--capability <kind>","Starter capability for --init (default: commands)",k).option("--install",`Install a ${o} source`).option("--dry-run","Resolve install sources and estimate copying without destination writes or activation").option("--uninstall",`Uninstall an installed ${o}`).option("--explore",`List discovered ${a} in selected scope`).option("--list","Alias for --explore").option("--manage",`List managed ${a} with update-check metadata`).option("--describe",`Map every surface a loaded ${o} registers (optionally one by name)`).option("--markdown","Render describe output as a Markdown reference document (describe only)").option("--output <path>","Write describe Markdown to a file (requires --markdown)").option("--reload",`Reload ${a} with cache-busted module imports`).option("--watch","Use watch mode with --reload").option("--doctor",`Run consolidated ${o} diagnostics (summary/deep modes)`).option("--catalog",`List bundled first-party ${o} catalog metadata`).option("--adopt",`Adopt an existing unmanaged ${o} into managed metadata`).option("--adopt-all",`Adopt all unmanaged ${a} into managed metadata`).option("--activate",`Activate a ${o} in selected scope settings`).option("--deactivate",`Deactivate a ${o} in selected scope settings`).option("--project",`Use project ${o} scope (default)`).option("--local","Alias for --project").option("--global",`Use global ${o} scope`).option("--gh <github-source>","Install from GitHub shorthand source (owner/repo[/path])").option("--github <github-source>","Alias for --gh").option("--ref <ref>","Git ref/branch/tag for GitHub install sources").option("--detail <mode>",`${o[0].toUpperCase()}${o.slice(1)} diagnostics detail mode (summary|deep)`).option("--trace","Include actionable registration traces in doctor deep diagnostics").option("--runtime-probe","Opt-in runtime activation probe for manage output parity").option("--fix-managed-state",`Adopt unmanaged ${a} before diagnostics/update checks`).option("--isolated",`Run doctor against project-scope ${a} only, ignoring global registrations`).option("--ignore-global","Alias for --isolated").option("--strict-exit","Return non-zero exit when doctor warnings are present (ok=false)").option("--fail-on-warn","Alias for --strict-exit (doctor)").description(t==="package"?"Manage package lifecycle in project or global scope.":"Manage extension lifecycle in project or global scope.").action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,void 0,t)});t==="package"&&(r.alias("packages"),r.option("--declarative","Scaffold the composeExtension blueprint starter (any capability)"));let c=r.command("init").alias("scaffold").argument("<target>","Scaffold target directory path").option("--capability <kind>",`Capability the starter targets (${U.join("|")}; default commands)`,k).description(t==="package"?"Generate a starter package scaffold with package metadata, manifest, and entrypoint.":"Generate a starter extension scaffold with manifest and entrypoint.");t==="package"&&c.option("--declarative","Scaffold the composeExtension blueprint starter (any capability)"),u(c,t).action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,"init",t)}),u(r.command("install").option("--dry-run","Resolve sources and estimate copying without destination writes or activation").argument("[targets...]",`${o[0].toUpperCase()}${o.slice(1)} source (local path, bundled alias, npm: source, wildcard, or GitHub source)`).option("--gh <github-source>","Install from GitHub shorthand source (owner/repo[/path])").option("--github <github-source>","Alias for --gh").option("--ref <ref>","Git ref/branch/tag for GitHub install sources").description(`Install ${o} from local path, bundled alias, npm: source, wildcard, or GitHub source.`),t).action(async(s,n,l)=>{await z(s,l.optsWithGlobals(),l,t)}),u(r.command("uninstall").argument("<target>",`${o[0].toUpperCase()}${o.slice(1)} name`).description(`Uninstall an installed ${o}.`),t).action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,"uninstall",t)}),u(r.command("explore").description(`List discovered ${a} in selected scope.`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"explore",t)}),u(r.command("manage").option("--runtime-probe","Opt-in runtime activation probe for manage output parity").option("--fix-managed-state",`Adopt unmanaged ${a} before diagnostics/update checks`).description(`List managed ${a} with update-check metadata.`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"manage",t)}),u(r.command("describe").argument("[target]",`${o[0].toUpperCase()}${o.slice(1)} name to describe (omit for every loaded ${o})`).option("--markdown","Render the surface map as a Markdown reference document instead of toon/json").option("--output <path>","Write Markdown output to a file (requires --markdown)").description(`Map every surface a loaded ${o} registers (commands, hooks, item types, providers, overrides, ...).`),t).action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,"describe",t)}),u(r.command("reload").option("--watch","Use watch mode for repeated reload checks").description(`Reload ${a} with cache-busted module imports.`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"reload",t)}),u(r.command("doctor").option("--detail <mode>",`Detail mode for ${o} diagnostics (summary|deep)`).option("--trace","Include actionable registration traces in doctor deep diagnostics").option("--fix-managed-state",`Adopt unmanaged ${a} before diagnostics/update checks`).option("--isolated",`Run doctor against project-scope ${a} only, ignoring global registrations`).option("--ignore-global","Alias for --isolated").option("--strict-exit","Return non-zero exit when doctor warnings are present (ok=false)").option("--fail-on-warn","Alias for --strict-exit (doctor)").description(`Run consolidated ${o} diagnostics (summary/deep modes).`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"doctor",t)}),u(r.command("catalog").alias("list").option("--fields <value>","Render compact comma-separated catalog fields, for example: alias,installed,install_command").description(`List bundled first-party ${o} catalog metadata.`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"catalog",t)}),u(r.command("adopt").argument("<target>",`${o[0].toUpperCase()}${o.slice(1)} name`).option("--gh <owner/repo[/path]>",`GitHub provenance shorthand for adopted ${o}`).option("--github <owner/repo[/path]>","Alias for --gh").option("--ref <ref>","Git ref/branch/tag for GitHub shorthand source").description(`Adopt an existing unmanaged ${o} into managed metadata.`),t).action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,"adopt",t)}),u(r.command("adopt-all").description(`Adopt all unmanaged ${a} into managed metadata.`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"adopt-all",t)}),u(r.command("migrate").option("--dry-run","Plan active migrations without invoking extension code").description(`Plan or apply active ${o} migrations with durable receipts.`),t).action(async(s,n)=>{await p(void 0,n.optsWithGlobals(),n,"migrate",t)}),u(r.command("activate").argument("<target>",`${o[0].toUpperCase()}${o.slice(1)} name`).description(`Activate a ${o} in selected scope settings.`),t).action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,"activate",t)}),u(r.command("deactivate").argument("<target>",`${o[0].toUpperCase()}${o.slice(1)} name`).description(`Deactivate a ${o} in selected scope settings.`),t).action(async(s,n,l)=>{await p(s,l.optsWithGlobals(),l,"deactivate",t)}),t==="package"&&N(x(r.command("upgrade").argument("[target]","Optional managed package name/source to upgrade; omit to upgrade pm CLI and all managed packages").description("Upgrade the pm CLI/SDK and refresh managed installable pm packages."))).action(async(s,n,l)=>{await q(s,l,!1)})}async function ie(e,t,o){let a=y(o),i=Date.now(),r=await T(e,a,{idPrefix:typeof t.idPrefix=="string"?t.idPrefix:void 0,preset:typeof t.preset=="string"?t.preset:void 0,defaults:t.defaults===!0||t.yes===!0,author:typeof t.author=="string"?t.author:void 0,agentGuidance:typeof t.agentGuidance=="string"?t.agentGuidance:void 0,typePreset:typeof t.typePreset=="string"?t.typePreset:void 0,withPackages:t.withPackages===!0,mergeFence:t.mergeFence!==!1,force:t.force===!0,workspace:typeof t.workspace=="string"?t.workspace:void 0}),s=t.verbose===!0||a.json===!0;w(s?r:L(r,!0),a),a.profile&&h(`profile:command=init took_ms=${Date.now()-i}`)}function ne(e,t,o,a){let r=e!==void 0&&new Set(["get","set","list","export"]).has(e);return{resolvedScope:r?"project":e??"project",resolvedAction:r?e:t??"list",resolvedKey:r?t:o,resolvedValue:r?o:a}}function re(e){return{criterion:Array.isArray(e.criterion)?e.criterion:[],format:typeof e.format=="string"?e.format:void 0,policy:typeof e.policy=="string"?e.policy:void 0,value:typeof e.value=="string"?e.value:void 0,clearCriteria:e.clearCriteria===!0,defaultDepth:typeof e.defaultDepth=="string"?e.defaultDepth:void 0,activityLimit:typeof e.activityLimit=="string"?e.activityLimit:void 0,staleThresholdDays:typeof e.staleThresholdDays=="string"?e.staleThresholdDays:void 0,sectionHierarchy:typeof e.sectionHierarchy=="string"?e.sectionHierarchy:void 0,sectionActivity:typeof e.sectionActivity=="string"?e.sectionActivity:void 0,sectionProgress:typeof e.sectionProgress=="string"?e.sectionProgress:void 0,sectionBlockers:typeof e.sectionBlockers=="string"?e.sectionBlockers:void 0,sectionFiles:typeof e.sectionFiles=="string"?e.sectionFiles:void 0,sectionWorkload:typeof e.sectionWorkload=="string"?e.sectionWorkload:void 0,sectionStaleness:typeof e.sectionStaleness=="string"?e.sectionStaleness:void 0,sectionTests:typeof e.sectionTests=="string"?e.sectionTests:void 0}}async function se(e,t,o,a,i,r){let c=y(r),s=Date.now(),{resolvedScope:n,resolvedAction:l,resolvedKey:f,resolvedValue:g}=ne(e,t,o,a),E=await j(n,l,f,re(i),c,typeof g=="string"?g:void 0);w(E,c),c.profile&&h(`profile:command=config took_ms=${Date.now()-s}`)}var Se={normalizeExtensionOptions:A};function Re(e){e.command("init").argument("[prefix-or-path]","Optional id prefix, or path-like tracker target such as ./pm-sandbox").option("--prefix, --id-prefix <value>","Set the item ID prefix (alias for the positional prefix)").option("--preset <value>","Governance preset for new setups: minimal|default|strict").option("--defaults","Use non-interactive setup defaults without opening the wizard").option("-y, --yes","Alias for --defaults (non-interactive setup)").option("--author <value>","Set the default mutation author for this project").option("--agent-guidance <mode>","Agent guidance mode: ask|add|skip|status").option("--type-preset <name>","Register domain item types during init: agile|ops|research").option("--with-packages","Install all bundled first-party packages during initialization").option("--no-merge-fence","Skip automatic merge-driver installation for a fresh Git-backed tracker").option("--workspace <dir>","Initialize repository-local tracker storage at <dir>/.agents/pm").option("--force","Allow initializing tracker files directly in a directory that looks like a workspace root").option("--verbose","Include the full resolved settings tree in the output (default output is a concise summary)").description("Initialize pm storage and defaults for the current workspace or a path-like tracker target.").action(async(t,o,a)=>{await ie(t,o,a)}),e.command("config").argument("[scope]","Config scope: project|global, or action shorthand list|export|get|set for project scope").argument("[action]","Config action: get|set|list|export").argument("[key]","Config key for get|set; use `pm config project list` for the complete typed inventory, including mutation-guard-* policies").argument("[value]",'Optional value for set: routed to the right typed flag by key (e.g. config set telemetry-tracking off, config set item-format toon, config set definition-of-done "Tests pass"). Equivalent to --policy/--format/--criterion. context keys still require --default-depth/--section-* flags.').option("--criterion <text>","Criteria value for definition-of-done, metadata-required-fields, or lifecycle pattern keys (repeatable for set)",k).option("--clear-criteria","Clear criteria-list keys for config set operations").option("--format <value>","Item format for item-format key: toon").option("--policy <value>","Policy key values: history-missing-stream-policy=auto_create|strict_error; sprint-release-format-policy=warn|strict_error; parent-reference-policy=warn|strict_error; governance-preset=minimal|default|strict|custom; governance-ownership-enforcement=none|warn|strict; governance-create-mode-default=progressive|strict; governance-close-validation-default=off|warn|strict; governance-require-close-reason=enabled|disabled; governance-parent-reference-policy=warn|strict_error; governance-metadata-validation-profile=core|strict|custom; governance-force-required-for-stale-lock=enabled|disabled; governance-duplicate-detection-mode=off|advisory|strict; test-result-tracking=enabled|disabled; untrusted-linked-test-execution=enabled|disabled; telemetry-tracking=enabled|disabled").option("--value <value>","Typed nested setting value. Mutation guards: require-attributed-author=true|false, secret-guard=off|advise|block, stale-in-progress-hours=integer>=1. Kebab-case is preferred; underscore aliases remain accepted.").option("--default-depth <value>","Context default depth: brief|standard|deep").option("--activity-limit <n>","Context default activity limit").option("--stale-threshold-days <n>","Context staleness cutoff in days").option("--section-hierarchy <value>","Enable/disable context hierarchy section (true|false)").option("--section-activity <value>","Enable/disable context activity section (true|false)").option("--section-progress <value>","Enable/disable context progress section (true|false)").option("--section-blockers <value>","Enable/disable context blockers section (true|false)").option("--section-files <value>","Enable/disable context files section (true|false)").option("--section-workload <value>","Enable/disable context workload section (true|false)").option("--section-staleness <value>","Enable/disable context staleness section (true|false)").option("--section-tests <value>","Enable/disable context tests section (true|false)").description("Read or update pm settings for the current workspace or global profile.").action(async(t,o,a,i,r,c)=>{await se(t,o,a,i,r,c)}),F(e,"extension"),F(e,"package"),x(e.command("install",{hidden:!0}).option("--dry-run","Resolve sources and estimate copying without destination writes or activation").argument("[targets...]","Package source (local path, bundled alias, npm: source, wildcard, or GitHub source)").option("--gh <github-source>","Install from GitHub shorthand source (owner/repo[/path])").option("--github <github-source>","Alias for --gh").option("--ref <ref>","Git ref/branch/tag for GitHub install sources").description("Install a pm package into the project package scope by default.")).action(async(t,o,a)=>{await _("install",a),await z(t,a.optsWithGlobals(),a,"package")}),N(x(e.command("upgrade",{hidden:!0}).argument("[target]","Optional managed package name/source to upgrade; omit to upgrade pm CLI and all managed packages").description("Upgrade the pm CLI/SDK and refresh managed installable pm packages."))).action(async(t,o,a)=>{await q(t,a,!0)})}export{Se as _testOnlyRegisterSetup,Re as registerSetupCommands};
2
- //# sourceMappingURL=register-setup-574SIVQZ.js.map