prizmkit 1.1.190 → 1.1.192
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/bin/create-prizmkit.js +4 -4
- package/bundled/VERSION.json +3 -3
- package/bundled/adapters/antigravity/assets/prizmkit-hook.cjs +150 -0
- package/bundled/adapters/antigravity/hooks-adapter.js +195 -0
- package/bundled/adapters/antigravity/paths.js +14 -0
- package/bundled/adapters/antigravity/rules-adapter.js +54 -0
- package/bundled/adapters/antigravity/skill-adapter.js +38 -0
- package/bundled/adapters/codex/skill-adapter.js +28 -8
- package/bundled/adapters/cursor/skill-adapter.js +13 -4
- package/bundled/adapters/pi/skill-adapter.js +28 -7
- package/bundled/dev-pipeline/.env.example +4 -12
- package/bundled/dev-pipeline/README.md +21 -15
- package/bundled/dev-pipeline/assets/skill-subagent-integration.md +3 -6
- package/bundled/dev-pipeline/prizmkit_runtime/atomic_io.py +48 -0
- package/bundled/dev-pipeline/prizmkit_runtime/checkpoint_state.py +66 -23
- package/bundled/dev-pipeline/prizmkit_runtime/cli.py +10 -7
- package/bundled/dev-pipeline/prizmkit_runtime/commands.py +2 -21
- package/bundled/dev-pipeline/prizmkit_runtime/config.py +29 -70
- package/bundled/dev-pipeline/prizmkit_runtime/daemon.py +125 -67
- package/bundled/dev-pipeline/prizmkit_runtime/gitops.py +89 -442
- package/bundled/dev-pipeline/prizmkit_runtime/heartbeat.py +93 -49
- package/bundled/dev-pipeline/prizmkit_runtime/interoperability.py +1 -3
- package/bundled/dev-pipeline/prizmkit_runtime/paths.py +0 -6
- package/bundled/dev-pipeline/prizmkit_runtime/platform_detection.py +49 -18
- package/bundled/dev-pipeline/prizmkit_runtime/processes.py +206 -151
- package/bundled/dev-pipeline/prizmkit_runtime/reset.py +2 -23
- package/bundled/dev-pipeline/prizmkit_runtime/reset_preserve.py +15 -134
- package/bundled/dev-pipeline/prizmkit_runtime/results.py +25 -0
- package/bundled/dev-pipeline/prizmkit_runtime/runner_bookkeeping.py +68 -83
- package/bundled/dev-pipeline/prizmkit_runtime/runner_classification.py +15 -5
- package/bundled/dev-pipeline/prizmkit_runtime/runner_models.py +1 -29
- package/bundled/dev-pipeline/prizmkit_runtime/runner_prompts.py +0 -2
- package/bundled/dev-pipeline/prizmkit_runtime/runner_status.py +7 -2
- package/bundled/dev-pipeline/prizmkit_runtime/runners.py +282 -217
- package/bundled/dev-pipeline/prizmkit_runtime/runtime_commit.py +124 -122
- package/bundled/dev-pipeline/prizmkit_runtime/runtime_helper.py +90 -9
- package/bundled/dev-pipeline/prizmkit_runtime/sessions.py +369 -154
- package/bundled/dev-pipeline/prizmkit_runtime/status.py +3 -3
- package/bundled/dev-pipeline/prizmkit_runtime/stream_progress.py +2780 -0
- package/bundled/dev-pipeline/prizmkit_runtime/task_checkout.py +27 -101
- package/bundled/dev-pipeline/prizmkit_runtime/test_result.py +58 -4
- package/bundled/dev-pipeline/scripts/check-session-status.py +43 -19
- package/bundled/dev-pipeline/scripts/continuation.py +6 -4
- package/bundled/dev-pipeline/scripts/detect-stuck.py +28 -28
- package/bundled/dev-pipeline/scripts/generate-bootstrap-prompt.py +7 -2
- package/bundled/dev-pipeline/scripts/generate-bugfix-prompt.py +7 -2
- package/bundled/dev-pipeline/scripts/init-bugfix-pipeline.py +10 -7
- package/bundled/dev-pipeline/scripts/init-change-artifact.py +8 -2
- package/bundled/dev-pipeline/scripts/init-pipeline.py +14 -69
- package/bundled/dev-pipeline/scripts/parse-stream-progress.py +31 -2328
- package/bundled/dev-pipeline/scripts/patch-completion-notes.py +4 -24
- package/bundled/dev-pipeline/scripts/prompt_framework.py +56 -9
- package/bundled/dev-pipeline/scripts/status_common.py +591 -0
- package/bundled/dev-pipeline/scripts/update-bug-status.py +85 -463
- package/bundled/dev-pipeline/scripts/update-checkpoint.py +227 -65
- package/bundled/dev-pipeline/scripts/update-feature-status.py +76 -509
- package/bundled/dev-pipeline/scripts/utils.py +10 -15
- package/bundled/dev-pipeline/templates/bootstrap-tier3.md +4 -4
- package/bundled/dev-pipeline/templates/bug-fix-list-schema.json +7 -0
- package/bundled/dev-pipeline/templates/bugfix-bootstrap-prompt.md +1 -1
- package/bundled/dev-pipeline/templates/sections/artifact-manifest.md +1 -1
- package/bundled/dev-pipeline/templates/sections/bugfix-phase-manual-verification.md +1 -1
- package/bundled/dev-pipeline/templates/sections/bugfix-phase-review.md +1 -1
- package/bundled/dev-pipeline/templates/sections/bugfix-phase-test.md +2 -1
- package/bundled/dev-pipeline/templates/sections/checkpoint-system.md +1 -1
- package/bundled/dev-pipeline/templates/sections/phase-browser-verification-auto.md +1 -1
- package/bundled/dev-pipeline/templates/sections/phase-browser-verification-opencli.md +2 -2
- package/bundled/dev-pipeline/templates/sections/phase-browser-verification.md +2 -2
- package/bundled/dev-pipeline/templates/sections/phase-prizmkit-test.md +2 -1
- package/bundled/dev-pipeline/templates/sections/phase-review-full.md +1 -1
- package/bundled/dev-pipeline/templates/sections/phase-specify-plan-full.md +3 -6
- package/bundled/dev-pipeline/templates/session-status-schema.json +2 -5
- package/bundled/dev-pipeline/tests/_helpers.py +418 -0
- package/bundled/dev-pipeline/tests/conftest.py +45 -1
- package/bundled/dev-pipeline/tests/live_ai_cli_log_smoke.py +1 -0
- package/bundled/dev-pipeline/tests/test_auto_skip.py +4 -69
- package/bundled/dev-pipeline/tests/test_checkpoint_state.py +126 -1
- package/bundled/dev-pipeline/tests/test_daemon_and_scripts.py +257 -0
- package/bundled/dev-pipeline/tests/test_e2e_pipeline_run.py +500 -0
- package/bundled/dev-pipeline/tests/test_generate_bootstrap_prompt.py +59 -117
- package/bundled/dev-pipeline/tests/test_generate_bugfix_prompt.py +12 -10
- package/bundled/dev-pipeline/tests/test_python_runner_parity.py +561 -3094
- package/bundled/dev-pipeline/tests/test_recovery_workflow.py +7 -8
- package/bundled/dev-pipeline/tests/test_repository_bootstrap.py +0 -1
- package/bundled/dev-pipeline/tests/test_reset_modes.py +15 -27
- package/bundled/dev-pipeline/tests/test_reset_preserve.py +54 -139
- package/bundled/dev-pipeline/tests/test_runner_bookkeeping.py +766 -0
- package/bundled/dev-pipeline/tests/test_runner_lifecycle.py +1257 -0
- package/bundled/dev-pipeline/tests/test_runtime_helper.py +97 -20
- package/bundled/dev-pipeline/tests/test_session_launch.py +1101 -0
- package/bundled/dev-pipeline/tests/test_stream_progress.py +585 -0
- package/bundled/dev-pipeline/tests/test_unified_cli.py +490 -2006
- package/bundled/dev-pipeline/tests/test_utils.py +3 -3
- package/bundled/rules/USAGE.md +1 -0
- package/bundled/skills/_metadata.json +9 -63
- package/bundled/skills/app-planner/SKILL.md +32 -303
- package/bundled/skills/app-planner/references/app-design-guide.md +0 -4
- package/bundled/skills/app-planner/references/generated-plan-review.md +2 -1
- package/bundled/skills/app-planner/references/project-brief-guide.md +14 -0
- package/bundled/skills/app-planner/references/project-conventions-discovery.md +4 -6
- package/bundled/skills/app-planner/references/project-state-detection.md +2 -3
- package/bundled/skills/bug-fix-workflow/SKILL.md +1 -2
- package/bundled/skills/bug-fix-workflow/references/bug-diagnosis.md +4 -7
- package/bundled/skills/bug-planner/SKILL.md +54 -435
- package/bundled/skills/bug-planner/references/generated-plan-review.md +3 -2
- package/bundled/skills/bug-planner/references/input-formats.md +32 -0
- package/bundled/skills/bugfix-pipeline-launcher/SKILL.md +4 -6
- package/bundled/skills/bugfix-pipeline-launcher/references/configuration.md +4 -28
- package/bundled/skills/feature-pipeline-launcher/SKILL.md +4 -6
- package/bundled/skills/feature-pipeline-launcher/references/configuration.md +4 -28
- package/bundled/skills/feature-planner/SKILL.md +60 -439
- package/bundled/skills/feature-planner/assets/planning-guide.md +1 -1
- package/bundled/skills/feature-planner/references/completeness-review.md +34 -0
- package/bundled/skills/feature-planner/references/decomposition-patterns.md +2 -2
- package/bundled/skills/feature-planner/references/error-recovery.md +1 -1
- package/bundled/skills/feature-planner/references/generated-plan-review.md +3 -2
- package/bundled/skills/feature-planner/references/incremental-feature-planning.md +3 -1
- package/bundled/skills/feature-workflow/SKILL.md +1 -2
- package/bundled/skills/prizmkit/SKILL.md +7 -1
- package/bundled/skills/prizmkit-code-review/SKILL.md +14 -6
- package/bundled/skills/prizmkit-code-review/references/independent-code-review.md +7 -4
- package/bundled/skills/prizmkit-code-review/references/review-report-template.md +16 -0
- package/bundled/skills/prizmkit-code-review/scripts/render_review_report.py +58 -20
- package/bundled/skills/prizmkit-implement/SKILL.md +1 -1
- package/bundled/skills/prizmkit-init/SKILL.md +25 -128
- package/bundled/skills/prizmkit-init/assets/project-brief-template.md +3 -3
- package/bundled/skills/prizmkit-init/references/config-schema.md +2 -2
- package/bundled/skills/prizmkit-plan/SKILL.md +6 -8
- package/bundled/skills/prizmkit-plan/references/clarify-guide.md +1 -1
- package/bundled/skills/prizmkit-plan/references/independent-plan-review.md +5 -2
- package/bundled/skills/prizmkit-plan/references/review-plan-spec-loop.md +6 -5
- package/bundled/skills/prizmkit-prizm-docs/SKILL.md +1 -13
- package/bundled/skills/prizmkit-prizm-docs/assets/prizm-docs-format.md +1 -1
- package/bundled/skills/prizmkit-prizm-docs/references/op-init.md +1 -1
- package/bundled/skills/prizmkit-prizm-docs/references/op-update.md +1 -1
- package/bundled/skills/prizmkit-retrospective/SKILL.md +6 -4
- package/bundled/skills/prizmkit-test/SKILL.md +25 -133
- package/bundled/skills/prizmkit-test/references/independent-test-review.md +5 -2
- package/bundled/skills/prizmkit-test/references/test-coverage-model.md +6 -0
- package/bundled/skills/prizmkit-workflow/SKILL.md +2 -3
- package/bundled/skills/prizmkit-workflow/references/workflow-state-protocol.md +4 -3
- package/bundled/skills/recovery-workflow/SKILL.md +7 -7
- package/bundled/skills/recovery-workflow/evals/evals.json +1 -1
- package/bundled/skills/recovery-workflow/references/detection.md +1 -3
- package/bundled/skills/recovery-workflow/scripts/detect-recovery-state.py +0 -6
- package/bundled/templates/project-memory-template.md +1 -2
- package/package.json +1 -1
- package/src/ai-cli-launch.js +1 -1
- package/src/clean.js +40 -4
- package/src/config.js +64 -4
- package/src/detect-platform.js +10 -6
- package/src/external-skills.js +2 -2
- package/src/index.js +1 -0
- package/src/manifest.js +1 -1
- package/src/platforms.js +6 -2
- package/src/prompts.js +11 -3
- package/src/scaffold.js +87 -11
- package/src/upgrade.js +9 -3
- package/bundled/dev-pipeline/SCHEMA_ANALYSIS.md +0 -53
- package/bundled/dev-pipeline/scripts/generate-refactor-prompt.py +0 -649
- package/bundled/dev-pipeline/scripts/init-refactor-pipeline.py +0 -463
- package/bundled/dev-pipeline/scripts/update-refactor-status.py +0 -1512
- package/bundled/dev-pipeline/templates/refactor-bootstrap-prompt.md +0 -240
- package/bundled/dev-pipeline/templates/refactor-list-schema.json +0 -266
- package/bundled/dev-pipeline/templates/sections/refactor-critical-paths.md +0 -15
- package/bundled/dev-pipeline/templates/sections/refactor-mission.md +0 -9
- package/bundled/dev-pipeline/templates/sections/refactor-phase-commit-report.md +0 -24
- package/bundled/dev-pipeline/templates/sections/refactor-phase-implement.md +0 -16
- package/bundled/dev-pipeline/templates/sections/refactor-phase-init.md +0 -9
- package/bundled/dev-pipeline/templates/sections/refactor-phase-plan.md +0 -22
- package/bundled/dev-pipeline/templates/sections/refactor-phase-review.md +0 -19
- package/bundled/dev-pipeline/templates/sections/refactor-phase-test.md +0 -24
- package/bundled/dev-pipeline/templates/sections/refactor-reminders.md +0 -12
- package/bundled/dev-pipeline/templates/sections/refactor-session-context.md +0 -6
- package/bundled/dev-pipeline/templates/sections/refactor-task-contract.md +0 -52
- package/bundled/dev-pipeline/tests/test_generate_refactor_prompt.py +0 -478
- package/bundled/skills/feature-planner/assets/evaluation-guide.md +0 -44
- package/bundled/skills/refactor-pipeline-launcher/SKILL.md +0 -219
- package/bundled/skills/refactor-pipeline-launcher/references/configuration.md +0 -78
- package/bundled/skills/refactor-planner/SKILL.md +0 -467
- package/bundled/skills/refactor-planner/assets/planning-guide.md +0 -291
- package/bundled/skills/refactor-planner/references/behavior-preservation.md +0 -187
- package/bundled/skills/refactor-planner/references/error-recovery.md +0 -45
- package/bundled/skills/refactor-planner/references/fast-path.md +0 -59
- package/bundled/skills/refactor-planner/references/generated-plan-review.md +0 -107
- package/bundled/skills/refactor-planner/references/planning-phases.md +0 -172
- package/bundled/skills/refactor-planner/references/refactor-scoping-guide.md +0 -230
- package/bundled/skills/refactor-planner/scripts/validate-and-generate-refactor.py +0 -1120
- package/bundled/skills/refactor-workflow/SKILL.md +0 -205
|
@@ -15,7 +15,6 @@ The identity is the validated artifact-directory basename. An existing state fil
|
|
|
15
15
|
```text
|
|
16
16
|
.prizmkit/specs/<requirement-slug>/
|
|
17
17
|
.prizmkit/bugfix/<bug-id>/
|
|
18
|
-
.prizmkit/refactor/<refactor-id>/
|
|
19
18
|
```
|
|
20
19
|
|
|
21
20
|
Never select another recent plan when resuming. Any external execution checkpoint remains separate from this state. Never merge, substitute, or infer one schema from the other.
|
|
@@ -53,7 +52,8 @@ Every consumer compares workflow state with the skill-owned artifacts and curren
|
|
|
53
52
|
"repair_scope": null,
|
|
54
53
|
"repair_round": 0,
|
|
55
54
|
"next_stage": "retrospective",
|
|
56
|
-
"resume_from": "prizmkit-retrospective"
|
|
55
|
+
"resume_from": "prizmkit-retrospective",
|
|
56
|
+
"terminal_status": null
|
|
57
57
|
}
|
|
58
58
|
```
|
|
59
59
|
|
|
@@ -72,6 +72,7 @@ Every consumer compares workflow state with the skill-owned artifacts and curren
|
|
|
72
72
|
| `repair_round` | Optional outer cross-stage repair round, from 0 through 3. It is not a test-internal repair counter. |
|
|
73
73
|
| `next_stage` | Next semantic stage, or null when stopped. |
|
|
74
74
|
| `resume_from` | Exact atomic skill that can resume, or null when none is selected. |
|
|
75
|
+
| `terminal_status` | Optional terminal lifecycle status: `null` while active, `WORKFLOW_COMPLETED` when all mandatory stages succeed, or `WORKFLOW_BLOCKED` when stopped on a blocker or repair limit. Never write terminal status values into `status`. |
|
|
75
76
|
|
|
76
77
|
`status` and `stage_result` are deliberately separate. Lifecycle status values must never be replaced with domain result values.
|
|
77
78
|
|
|
@@ -123,7 +124,7 @@ When consistent Test artifacts return `TEST_PASS` with `production_changed=true`
|
|
|
123
124
|
5. sets `repair_scope=production`, `next_stage=code-review`, and `resume_from=prizmkit-code-review`;
|
|
124
125
|
6. invokes delta Code Review and then a fresh Test.
|
|
125
126
|
|
|
126
|
-
A fresh `TEST_PASS` with `production_changed=false` may complete Test and advance. Another production-changing pass repeats this route within the same outer budget. When `repair_round >= 3`, set `WORKFLOW_BLOCKED` without Retrospective or commit progression.
|
|
127
|
+
A fresh `TEST_PASS` with `production_changed=false` may complete Test and advance. Another production-changing pass repeats this route within the same outer budget. When `repair_round >= 3`, set `terminal_status=WORKFLOW_BLOCKED` (keeping `status=failed`) without Retrospective or commit progression.
|
|
127
128
|
|
|
128
129
|
## Non-Pass Results and Routing Boundary
|
|
129
130
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: "recovery-workflow"
|
|
3
|
-
description: "Return the exact PrizmKit CLI command that continues an interrupted feature
|
|
3
|
+
description: "Return the exact PrizmKit CLI command that continues an interrupted feature or bugfix task on its recorded task branch. Use when a pipeline process or AI session stopped unexpectedly and the user asks to recover, resume, continue, pick up, or salvage that task. This skill detects active task checkout records and reports commands; it does not reconstruct lifecycle phases or run recovery prompts."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Recovery Workflow
|
|
@@ -12,7 +12,7 @@ This skill invokes its own bundled detector. The canonical runtime exposes no se
|
|
|
12
12
|
## Boundary
|
|
13
13
|
|
|
14
14
|
This workflow:
|
|
15
|
-
- Detects active feature
|
|
15
|
+
- Detects active feature and bugfix task checkout records.
|
|
16
16
|
- Confirms that each recorded task branch still exists.
|
|
17
17
|
- Returns the exact item-specific `cli.py run <family> <TASK_ID>` command.
|
|
18
18
|
- Shows the branch, task family, task ID, and checkout record that justify the command.
|
|
@@ -37,16 +37,17 @@ The detector reads only active checkout records:
|
|
|
37
37
|
```text
|
|
38
38
|
.prizmkit/state/features/<F-NNN>/checkout.json
|
|
39
39
|
.prizmkit/state/bugfix/<B-NNN>/checkout.json
|
|
40
|
-
.prizmkit/state/refactor/<R-NNN>/checkout.json
|
|
41
40
|
```
|
|
42
41
|
|
|
43
42
|
A candidate is resumable only when:
|
|
44
43
|
- `state` is `active`;
|
|
45
44
|
- `task_type` equals the checkout directory family;
|
|
46
|
-
- `task_id` is explicitly recorded, matches the exact `F-NNN
|
|
45
|
+
- `task_id` is explicitly recorded, matches the exact `F-NNN` or `B-NNN` family form, and equals its parent state-directory name;
|
|
47
46
|
- `active_dev_branch` is present; and
|
|
48
47
|
- the recorded local branch still exists.
|
|
49
48
|
|
|
49
|
+
Read `${SKILL_DIR}/references/detection.md` only when the user asks for detector diagnostics or validation rules for ignored or missing-branch checkout records.
|
|
50
|
+
|
|
50
51
|
The runtime uses the same checkout record when the returned command starts, so it continues on the recorded branch rather than creating a new branch.
|
|
51
52
|
|
|
52
53
|
## Selection
|
|
@@ -76,7 +77,6 @@ Return the detector-provided command verbatim. The canonical forms are:
|
|
|
76
77
|
```bash
|
|
77
78
|
python3 ./.prizmkit/dev-pipeline/cli.py run feature F-001
|
|
78
79
|
python3 ./.prizmkit/dev-pipeline/cli.py run bugfix B-001
|
|
79
|
-
python3 ./.prizmkit/dev-pipeline/cli.py run refactor R-001
|
|
80
80
|
```
|
|
81
81
|
|
|
82
82
|
Do not prepend `git checkout`. The runtime resolves the durable checkout identity and continues the task on its recorded branch or linked worktree.
|
|
@@ -89,8 +89,8 @@ Use this exact structure:
|
|
|
89
89
|
|
|
90
90
|
```text
|
|
91
91
|
INTERRUPTED_TASK_FOUND
|
|
92
|
-
family: <feature | bugfix
|
|
93
|
-
task_id: <F-NNN | B-NNN
|
|
92
|
+
family: <feature | bugfix>
|
|
93
|
+
task_id: <F-NNN | B-NNN>
|
|
94
94
|
branch: <recorded active_dev_branch>
|
|
95
95
|
checkout: <project-relative checkout.json path>
|
|
96
96
|
command:
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"name": "multiple-interrupted-tasks",
|
|
24
24
|
"prompt": "Continue whichever pipeline task was interrupted.",
|
|
25
25
|
"expected_output": "Detect multiple active checkout records and ask the user to select by task ID, family, and branch before returning one command.",
|
|
26
|
-
"setup_description": "Create active feature and
|
|
26
|
+
"setup_description": "Create active feature and bugfix checkout records whose local branches both exist.",
|
|
27
27
|
"files": []
|
|
28
28
|
},
|
|
29
29
|
{
|
|
@@ -7,14 +7,13 @@ Recovery uses the runtime's durable task checkout identity rather than reconstru
|
|
|
7
7
|
```text
|
|
8
8
|
.prizmkit/state/features/<F-NNN>/checkout.json
|
|
9
9
|
.prizmkit/state/bugfix/<B-NNN>/checkout.json
|
|
10
|
-
.prizmkit/state/refactor/<R-NNN>/checkout.json
|
|
11
10
|
```
|
|
12
11
|
|
|
13
12
|
A record is resumable only when:
|
|
14
13
|
|
|
15
14
|
1. `state` equals `active`.
|
|
16
15
|
2. `task_type` equals the checkout directory family.
|
|
17
|
-
3. `task_id` is explicitly present, matches the exact `F-NNN
|
|
16
|
+
3. `task_id` is explicitly present, matches the exact `F-NNN` or `B-NNN` family form, and equals its parent state-directory name.
|
|
18
17
|
4. `active_dev_branch` is non-empty.
|
|
19
18
|
5. `refs/heads/<active_dev_branch>` exists locally.
|
|
20
19
|
|
|
@@ -27,7 +26,6 @@ The item-specific foreground command reloads the active checkout record and reus
|
|
|
27
26
|
```bash
|
|
28
27
|
python3 ./.prizmkit/dev-pipeline/cli.py run feature <F-NNN>
|
|
29
28
|
python3 ./.prizmkit/dev-pipeline/cli.py run bugfix <B-NNN>
|
|
30
|
-
python3 ./.prizmkit/dev-pipeline/cli.py run refactor <R-NNN>
|
|
31
29
|
```
|
|
32
30
|
|
|
33
31
|
The command does not need an explicit branch argument. Do not prepend `git checkout`, because the runtime owns checkout identity and branch/worktree reuse.
|
|
@@ -23,12 +23,6 @@ FAMILIES = (
|
|
|
23
23
|
"plan_path": ".prizmkit/plans/bug-fix-list.json",
|
|
24
24
|
"id_pattern": r"^B-\d{3}$",
|
|
25
25
|
},
|
|
26
|
-
{
|
|
27
|
-
"name": "refactor",
|
|
28
|
-
"state_dir": "refactor",
|
|
29
|
-
"plan_path": ".prizmkit/plans/refactor-list.json",
|
|
30
|
-
"id_pattern": r"^R-\d{3}$",
|
|
31
|
-
},
|
|
32
26
|
)
|
|
33
27
|
|
|
34
28
|
|
|
@@ -35,13 +35,12 @@ Run `/prizmkit` to see all available PrizmKit commands.
|
|
|
35
35
|
|
|
36
36
|
### Python Runtime CLI Quick Reference
|
|
37
37
|
|
|
38
|
-
Placeholders: `<family> = feature | bugfix
|
|
38
|
+
Placeholders: `<family> = feature | bugfix`; `<task-id> = F-NNN | B-NNN`; `<list>` is optional and defaults by family:
|
|
39
39
|
|
|
40
40
|
| `<family>` | Default `<list>` |
|
|
41
41
|
|---|---|
|
|
42
42
|
| `feature` | `.prizmkit/plans/feature-list.json` |
|
|
43
43
|
| `bugfix` | `.prizmkit/plans/bug-fix-list.json` |
|
|
44
|
-
| `refactor` | `.prizmkit/plans/refactor-list.json` |
|
|
45
44
|
|
|
46
45
|
```bash
|
|
47
46
|
# Run/resume the whole list or one task
|
package/package.json
CHANGED
package/src/ai-cli-launch.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const BUILT_IN_AI_CLI_NAMES = new Set(['claude', 'cbc', 'codebuddy', 'codex', 'pi', 'agent']);
|
|
1
|
+
const BUILT_IN_AI_CLI_NAMES = new Set(['claude', 'cbc', 'codebuddy', 'codex', 'pi', 'agent', 'agy', 'antigravity']);
|
|
2
2
|
|
|
3
3
|
function asText(value) {
|
|
4
4
|
return typeof value === 'string' ? value : '';
|
package/src/clean.js
CHANGED
|
@@ -4,7 +4,7 @@ import fs from 'fs-extra';
|
|
|
4
4
|
import { pathToFileURL } from 'node:url';
|
|
5
5
|
import { getAdaptersDir, loadMetadata, loadRulesMetadata } from './metadata.js';
|
|
6
6
|
import { readManifestForLifecycle } from './manifest.js';
|
|
7
|
-
import { privateProjectMemoryFile, projectMemoryFile } from './platforms.js';
|
|
7
|
+
import { PLATFORM_IDS, privateProjectMemoryFile, projectMemoryFile } from './platforms.js';
|
|
8
8
|
|
|
9
9
|
// Cleanup owns only deterministic private host-memory entries. Existing
|
|
10
10
|
// `.prizmkit/**` ignore policy is project-owned and must remain untouched.
|
|
@@ -183,6 +183,18 @@ async function removeCursorHooks(projectRoot, dryRun) {
|
|
|
183
183
|
}));
|
|
184
184
|
}
|
|
185
185
|
|
|
186
|
+
async function removeAntigravityHooks(projectRoot, dryRun) {
|
|
187
|
+
const adapterPath = path.join(getAdaptersDir(), 'antigravity', 'hooks-adapter.js');
|
|
188
|
+
const { removeHooks } = await import(pathToFileURL(adapterPath).href);
|
|
189
|
+
return (await removeHooks(projectRoot, dryRun)).map(change => ({
|
|
190
|
+
path: path.join(projectRoot, change.path),
|
|
191
|
+
removed: !dryRun && change.action === 'removed',
|
|
192
|
+
updated: !dryRun && change.action === 'updated',
|
|
193
|
+
reason: dryRun ? 'dry_run' : undefined,
|
|
194
|
+
note: change.action === 'updated' ? '(PrizmKit hook entries)' : undefined,
|
|
195
|
+
}));
|
|
196
|
+
}
|
|
197
|
+
|
|
186
198
|
export async function runClean(directory, options = {}) {
|
|
187
199
|
const projectRoot = path.resolve(directory || '.');
|
|
188
200
|
const dryRun = Boolean(options.dryRun);
|
|
@@ -204,8 +216,9 @@ export async function runClean(directory, options = {}) {
|
|
|
204
216
|
// Read manifest for accurate cleanup (covers skills from older versions)
|
|
205
217
|
const manifest = await readManifestForLifecycle(projectRoot);
|
|
206
218
|
|
|
207
|
-
// Validate and merge-remove Cursor hooks before any destructive cleanup.
|
|
219
|
+
// Validate and merge-remove Cursor and Antigravity hooks before any destructive cleanup.
|
|
208
220
|
const cursorHookResults = await removeCursorHooks(projectRoot, dryRun);
|
|
221
|
+
const antigravityHookResults = await removeAntigravityHooks(projectRoot, dryRun);
|
|
209
222
|
|
|
210
223
|
const metadataSkillNames = Object.keys(metadata.skills);
|
|
211
224
|
const externalSkillNames = (metadata.external_skills?.known || []).map(s => s.name);
|
|
@@ -273,6 +286,10 @@ export async function runClean(directory, options = {}) {
|
|
|
273
286
|
const cursorSkillsDir = path.join(projectRoot, '.cursor', 'skills');
|
|
274
287
|
results.push(...await removeKnownEntries(cursorSkillsDir, allSkillNames, dryRun));
|
|
275
288
|
|
|
289
|
+
// .agents/plugins/prizmkit/skills/ — Antigravity project plugin Skills
|
|
290
|
+
const antigravitySkillsDir = path.join(projectRoot, '.agents', 'plugins', 'prizmkit', 'skills');
|
|
291
|
+
results.push(...await removeKnownEntries(antigravitySkillsDir, allSkillNames, dryRun));
|
|
292
|
+
|
|
276
293
|
// .claude/agents/ — retired PrizmKit named-agent files
|
|
277
294
|
const claudeAgentsDir = path.join(projectRoot, '.claude', 'agents');
|
|
278
295
|
results.push(...await removeKnownEntries(claudeAgentsDir, agentFiles, dryRun));
|
|
@@ -312,7 +329,15 @@ export async function runClean(directory, options = {}) {
|
|
|
312
329
|
));
|
|
313
330
|
results.push(...cursorHookResults);
|
|
314
331
|
|
|
315
|
-
|
|
332
|
+
const antigravityRulesDir = path.join(projectRoot, '.agents', 'plugins', 'prizmkit', 'rules');
|
|
333
|
+
results.push(...await removeKnownEntries(
|
|
334
|
+
antigravityRulesDir,
|
|
335
|
+
[...ruleFileNames.map(n => `${n}.md`), 'prizmkit-framework.md'],
|
|
336
|
+
dryRun,
|
|
337
|
+
));
|
|
338
|
+
results.push(...antigravityHookResults);
|
|
339
|
+
|
|
340
|
+
for (const platform of PLATFORM_IDS) {
|
|
316
341
|
const memoryFile = projectMemoryFile(platform);
|
|
317
342
|
const privateMemoryFile = privateProjectMemoryFile(platform);
|
|
318
343
|
if (!privateMemoryFile) continue;
|
|
@@ -324,7 +349,18 @@ export async function runClean(directory, options = {}) {
|
|
|
324
349
|
}
|
|
325
350
|
|
|
326
351
|
if (!dryRun) {
|
|
327
|
-
for (const relativeDir of [
|
|
352
|
+
for (const relativeDir of [
|
|
353
|
+
'.cursor/hooks',
|
|
354
|
+
'.cursor/rules',
|
|
355
|
+
'.cursor/skills',
|
|
356
|
+
'.cursor',
|
|
357
|
+
'.agents/plugins/prizmkit/hooks',
|
|
358
|
+
'.agents/plugins/prizmkit/rules',
|
|
359
|
+
'.agents/plugins/prizmkit/skills',
|
|
360
|
+
'.agents/plugins/prizmkit',
|
|
361
|
+
'.agents/plugins',
|
|
362
|
+
'.agents',
|
|
363
|
+
]) {
|
|
328
364
|
const dir = path.join(projectRoot, relativeDir);
|
|
329
365
|
if (await fs.pathExists(dir) && (await fs.readdir(dir)).length === 0) await fs.remove(dir);
|
|
330
366
|
}
|
package/src/config.js
CHANGED
|
@@ -112,6 +112,42 @@ async function removeCursorManagedFiles(projectRoot, dryRun) {
|
|
|
112
112
|
}
|
|
113
113
|
}
|
|
114
114
|
|
|
115
|
+
async function removeAntigravityManagedFiles(projectRoot, dryRun) {
|
|
116
|
+
const adapterPath = path.join(getAdaptersDir(), 'antigravity', 'hooks-adapter.js');
|
|
117
|
+
const { removeHooks } = await import(pathToFileURL(adapterPath).href);
|
|
118
|
+
for (const change of await removeHooks(projectRoot, dryRun)) {
|
|
119
|
+
const verb = change.action === 'updated' ? 'update' : 'remove';
|
|
120
|
+
console.log(dryRun
|
|
121
|
+
? chalk.gray(` [dry-run] ${verb} ${change.path}`)
|
|
122
|
+
: change.action === 'updated'
|
|
123
|
+
? chalk.green(` ✓ updated ${change.path} (removed PrizmKit hooks)`)
|
|
124
|
+
: chalk.red(` ✗ removed ${change.path}`));
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
const guidancePath = path.join(projectRoot, '.agents', 'plugins', 'prizmkit', 'rules', 'prizmkit-framework.md');
|
|
128
|
+
if (await fs.pathExists(guidancePath)) {
|
|
129
|
+
if (dryRun) console.log(chalk.gray(' [dry-run] remove .agents/plugins/prizmkit/rules/prizmkit-framework.md'));
|
|
130
|
+
else {
|
|
131
|
+
await fs.remove(guidancePath);
|
|
132
|
+
console.log(chalk.red(' ✗ removed .agents/plugins/prizmkit/rules/prizmkit-framework.md'));
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
if (!dryRun) {
|
|
137
|
+
for (const relativeDir of [
|
|
138
|
+
'.agents/plugins/prizmkit/hooks',
|
|
139
|
+
'.agents/plugins/prizmkit/rules',
|
|
140
|
+
'.agents/plugins/prizmkit/skills',
|
|
141
|
+
'.agents/plugins/prizmkit',
|
|
142
|
+
'.agents/plugins',
|
|
143
|
+
'.agents',
|
|
144
|
+
]) {
|
|
145
|
+
const dir = path.join(projectRoot, relativeDir);
|
|
146
|
+
if (await fs.pathExists(dir) && (await fs.readdir(dir)).length === 0) await fs.remove(dir);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
|
|
115
151
|
/**
|
|
116
152
|
* Detect which platforms are actually installed on filesystem.
|
|
117
153
|
*/
|
|
@@ -130,7 +166,16 @@ async function detectInstalledPlatforms(projectRoot) {
|
|
|
130
166
|
const hasCodex = await hasPlatformFiles(path.join(projectRoot, '.agents', 'skills'));
|
|
131
167
|
const hasPi = await hasPlatformFiles(path.join(projectRoot, '.pi', 'skills'));
|
|
132
168
|
const hasCursor = await hasPlatformFiles(path.join(projectRoot, '.cursor', 'skills'));
|
|
133
|
-
const
|
|
169
|
+
const hasAntigravity = await fs.pathExists(path.join(projectRoot, '.agents', 'plugins', 'prizmkit', 'plugin.json'))
|
|
170
|
+
|| await hasPlatformFiles(path.join(projectRoot, '.agents', 'plugins', 'prizmkit', 'skills'));
|
|
171
|
+
const detected = [
|
|
172
|
+
hasCodeBuddy && 'codebuddy',
|
|
173
|
+
hasClaude && 'claude',
|
|
174
|
+
hasCodex && 'codex',
|
|
175
|
+
hasPi && 'pi',
|
|
176
|
+
hasCursor && 'cursor',
|
|
177
|
+
hasAntigravity && 'antigravity',
|
|
178
|
+
].filter(Boolean);
|
|
134
179
|
if (detected.length === 0) return null;
|
|
135
180
|
return uniquePlatforms(detected).join(',');
|
|
136
181
|
}
|
|
@@ -246,8 +291,9 @@ async function migrateProjectMemoryOnPlatformDrop(droppedPlatform, newPlatforms,
|
|
|
246
291
|
* Selective removal — only removes known PrizmKit files, leaves user-created files intact.
|
|
247
292
|
*/
|
|
248
293
|
async function removePlatformFiles(platform, projectRoot, manifest, dryRun) {
|
|
249
|
-
// Validate and remove merge-sensitive Cursor hooks before any other platform mutation.
|
|
294
|
+
// Validate and remove merge-sensitive Cursor/Antigravity hooks before any other platform mutation.
|
|
250
295
|
if (platform === 'cursor') await removeCursorManagedFiles(projectRoot, dryRun);
|
|
296
|
+
if (platform === 'antigravity') await removeAntigravityManagedFiles(projectRoot, dryRun);
|
|
251
297
|
|
|
252
298
|
const skillNames = manifest?.files?.skills || [];
|
|
253
299
|
const ruleFileNames = manifest?.files?.rules || [];
|
|
@@ -272,8 +318,8 @@ async function removePlatformFiles(platform, projectRoot, manifest, dryRun) {
|
|
|
272
318
|
}
|
|
273
319
|
|
|
274
320
|
// Settings
|
|
275
|
-
if (platform === 'cursor') {
|
|
276
|
-
// Merge-sensitive
|
|
321
|
+
if (platform === 'cursor' || platform === 'antigravity') {
|
|
322
|
+
// Merge-sensitive hooks and managed framework guidance were handled first.
|
|
277
323
|
} else if (platform === 'codex') {
|
|
278
324
|
await removeGeneratedCodexConfig(projectRoot, dryRun);
|
|
279
325
|
const legacySettingsFile = path.join(projectRoot, '.codex', 'prizmkit-settings.json');
|
|
@@ -414,6 +460,20 @@ async function removePlatformFiles(platform, projectRoot, manifest, dryRun) {
|
|
|
414
460
|
await fs.remove(dir);
|
|
415
461
|
}
|
|
416
462
|
}
|
|
463
|
+
} else if (platform === 'antigravity') {
|
|
464
|
+
for (const relativeDir of [
|
|
465
|
+
'.agents/plugins/prizmkit/skills',
|
|
466
|
+
'.agents/plugins/prizmkit/rules',
|
|
467
|
+
'.agents/plugins/prizmkit/hooks',
|
|
468
|
+
'.agents/plugins/prizmkit',
|
|
469
|
+
'.agents/plugins',
|
|
470
|
+
'.agents',
|
|
471
|
+
]) {
|
|
472
|
+
const dir = path.join(projectRoot, relativeDir);
|
|
473
|
+
if (await fs.pathExists(dir) && !dryRun && (await fs.readdir(dir)).length === 0) {
|
|
474
|
+
await fs.remove(dir);
|
|
475
|
+
}
|
|
476
|
+
}
|
|
417
477
|
}
|
|
418
478
|
}
|
|
419
479
|
|
package/src/detect-platform.js
CHANGED
|
@@ -9,7 +9,7 @@ import os from 'os';
|
|
|
9
9
|
/**
|
|
10
10
|
* 允许检测的命令白名单(仅用于 which 检测)
|
|
11
11
|
*/
|
|
12
|
-
const ALLOWED_COMMANDS = ['cbc', 'claude', 'codex', 'pi', 'agent'];
|
|
12
|
+
const ALLOWED_COMMANDS = ['cbc', 'claude', 'codex', 'pi', 'agent', 'agy'];
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* 检查命令是否存在于 PATH 中
|
|
@@ -51,7 +51,7 @@ function cursorAgentExists() {
|
|
|
51
51
|
* 注意:platform 控制目录结构,suggestedCli 是实际运行的可执行命令。
|
|
52
52
|
* Cursor 的 `agent` 名称通用,只有安全的 version/help 身份探测通过才自动选择。
|
|
53
53
|
*
|
|
54
|
-
* @returns {{ cbc: boolean, claude: boolean, codex: boolean, pi: boolean, cursor: boolean, suggested: string, suggestedCli: string }}
|
|
54
|
+
* @returns {{ cbc: boolean, claude: boolean, codex: boolean, pi: boolean, cursor: boolean, antigravity: boolean, suggested: string, suggestedCli: string }}
|
|
55
55
|
*/
|
|
56
56
|
export function detectPlatform() {
|
|
57
57
|
const cbc = commandExists('cbc');
|
|
@@ -59,10 +59,13 @@ export function detectPlatform() {
|
|
|
59
59
|
const codex = commandExists('codex');
|
|
60
60
|
const pi = commandExists('pi');
|
|
61
61
|
const cursor = cursorAgentExists();
|
|
62
|
+
const antigravity = commandExists('agy');
|
|
62
63
|
|
|
63
|
-
// Preserve historical recommendations when
|
|
64
|
+
// Preserve historical recommendations when newer platforms are absent.
|
|
64
65
|
let suggested = 'codebuddy';
|
|
65
|
-
if (
|
|
66
|
+
if (antigravity) {
|
|
67
|
+
suggested = (cbc || claude || codex || pi || cursor) ? 'all' : 'antigravity';
|
|
68
|
+
} else if (cursor) {
|
|
66
69
|
suggested = (cbc || claude || codex || pi) ? 'all' : 'cursor';
|
|
67
70
|
} else if (pi) {
|
|
68
71
|
suggested = (cbc || claude || codex) ? 'all' : 'pi';
|
|
@@ -76,13 +79,14 @@ export function detectPlatform() {
|
|
|
76
79
|
suggested = 'codebuddy';
|
|
77
80
|
}
|
|
78
81
|
|
|
79
|
-
// Preserve historical precedence and use
|
|
82
|
+
// Preserve historical precedence and use newer CLIs only when earlier ones are absent.
|
|
80
83
|
let suggestedCli = '';
|
|
81
84
|
if (cbc) suggestedCli = 'cbc';
|
|
82
85
|
else if (claude) suggestedCli = 'claude';
|
|
83
86
|
else if (codex) suggestedCli = 'codex';
|
|
84
87
|
else if (pi) suggestedCli = 'pi';
|
|
85
88
|
else if (cursor) suggestedCli = 'agent';
|
|
89
|
+
else if (antigravity) suggestedCli = 'agy';
|
|
86
90
|
|
|
87
|
-
return { cbc, claude, codex, pi, cursor, suggested, suggestedCli };
|
|
91
|
+
return { cbc, claude, codex, pi, cursor, antigravity, suggested, suggestedCli };
|
|
88
92
|
}
|
package/src/external-skills.js
CHANGED
|
@@ -22,7 +22,7 @@ import { payloadSkillRoots } from './platforms.js';
|
|
|
22
22
|
* skill.repo {string} - GitHub short ref (e.g. "pbakaus/impeccable") or full URL
|
|
23
23
|
* skill.name {string} - Skill name (used for display / single-skill mode)
|
|
24
24
|
* skill.installAll {boolean} - If true, install all skills from the repo
|
|
25
|
-
* @param {string} platform - 'claude' | 'codebuddy' | 'codex' | 'pi' | 'cursor' | 'all' ('both' supported only for legacy manifests)
|
|
25
|
+
* @param {string} platform - 'claude' | 'codebuddy' | 'codex' | 'pi' | 'cursor' | 'antigravity' | 'all' ('both' supported only for legacy manifests)
|
|
26
26
|
* @param {string} projectRoot - Target project root
|
|
27
27
|
* @param {string} [aiCli] - optional AI CLI command that may require an additional payload platform
|
|
28
28
|
*/
|
|
@@ -87,7 +87,7 @@ export async function installExternalSkill(skill, platform, projectRoot, dryRun,
|
|
|
87
87
|
* Remove all artifacts created by `npx skills` that are not needed by PrizmKit.
|
|
88
88
|
* Call this once after all external skills have been installed.
|
|
89
89
|
*
|
|
90
|
-
* @param {string} platform - 'claude' | 'codebuddy' | 'codex' | 'pi' | 'cursor' | 'all' ('both' supported only for legacy manifests)
|
|
90
|
+
* @param {string} platform - 'claude' | 'codebuddy' | 'codex' | 'pi' | 'cursor' | 'antigravity' | 'all' ('both' supported only for legacy manifests)
|
|
91
91
|
* @param {string} [aiCli] - optional AI CLI command that may require an additional payload platform
|
|
92
92
|
*/
|
|
93
93
|
export async function cleanExternalSkillArtifacts(projectRoot, platform, aiCli = '') {
|
package/src/index.js
CHANGED
|
@@ -54,6 +54,7 @@ export async function runScaffold(directory, options) {
|
|
|
54
54
|
detected.codex ? chalk.green('codex ✓') : chalk.gray('codex ✗'),
|
|
55
55
|
detected.pi ? chalk.green('pi ✓') : chalk.gray('pi ✗'),
|
|
56
56
|
detected.cursor ? chalk.green('agent(Cursor) ✓') : chalk.gray('agent(Cursor) ✗'),
|
|
57
|
+
detected.antigravity ? chalk.green('agy ✓') : chalk.gray('agy ✗'),
|
|
57
58
|
].join(' ');
|
|
58
59
|
console.log(` 检测到的 CLI 工具: ${cliStatus}`);
|
|
59
60
|
console.log(` 目标目录: ${projectRoot}`);
|
package/src/manifest.js
CHANGED
|
@@ -133,7 +133,7 @@ export async function writeManifest(projectRoot, data) {
|
|
|
133
133
|
* Build a manifest object from installation config.
|
|
134
134
|
* @param {Object} params
|
|
135
135
|
* @param {string} params.version - PrizmKit version
|
|
136
|
-
* @param {string} params.platform - 'codebuddy' | 'claude' | 'codex' | 'pi' | 'cursor' | 'all' ('both' supported only for legacy manifests)
|
|
136
|
+
* @param {string} params.platform - 'codebuddy' | 'claude' | 'codex' | 'pi' | 'cursor' | 'antigravity' | 'all' ('both' supported only for legacy manifests)
|
|
137
137
|
* @param {string} [params.runtime] - canonical Python runtime id or compatibility alias
|
|
138
138
|
* @param {string} params.suite - skill suite name
|
|
139
139
|
* @param {string[]} params.skills - resolved skill name list
|
package/src/platforms.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import path from 'path';
|
|
2
2
|
import { isBuiltInAiCli } from './ai-cli-launch.js';
|
|
3
3
|
|
|
4
|
-
export const PLATFORM_IDS = ['codebuddy', 'claude', 'codex', 'pi', 'cursor'];
|
|
5
|
-
export const PLATFORM_INPUT_HELP = 'codebuddy, claude, codex, pi, cursor, a comma-separated list of those, or all';
|
|
4
|
+
export const PLATFORM_IDS = ['codebuddy', 'claude', 'codex', 'pi', 'cursor', 'antigravity'];
|
|
5
|
+
export const PLATFORM_INPUT_HELP = 'codebuddy, claude, codex, pi, cursor, antigravity, a comma-separated list of those, or all';
|
|
6
6
|
export const CANONICAL_ALL_PLATFORMS = PLATFORM_IDS.join(',');
|
|
7
7
|
|
|
8
8
|
const HOST_LABELS = {
|
|
@@ -11,6 +11,7 @@ const HOST_LABELS = {
|
|
|
11
11
|
codex: 'Codex',
|
|
12
12
|
pi: 'Pi',
|
|
13
13
|
cursor: 'Cursor',
|
|
14
|
+
antigravity: 'Antigravity',
|
|
14
15
|
};
|
|
15
16
|
|
|
16
17
|
export function unknownPlatformMessage(platform) {
|
|
@@ -70,6 +71,7 @@ export function platformFromAiCli(aiCli) {
|
|
|
70
71
|
if (name === 'codex') return 'codex';
|
|
71
72
|
if (name === 'pi') return 'pi';
|
|
72
73
|
if (name === 'agent') return 'cursor';
|
|
74
|
+
if (name === 'agy' || name === 'antigravity') return 'antigravity';
|
|
73
75
|
if (name === 'cbc' || name === 'codebuddy') return 'codebuddy';
|
|
74
76
|
return null;
|
|
75
77
|
}
|
|
@@ -138,6 +140,7 @@ export function defaultCliForPlatform(platform) {
|
|
|
138
140
|
if (platform === 'codex') return 'codex';
|
|
139
141
|
if (platform === 'pi') return 'pi';
|
|
140
142
|
if (platform === 'cursor') return 'agent';
|
|
143
|
+
if (platform === 'antigravity') return 'agy';
|
|
141
144
|
return '';
|
|
142
145
|
}
|
|
143
146
|
|
|
@@ -146,6 +149,7 @@ export function nativeSkillRoot(platform, projectRoot) {
|
|
|
146
149
|
if (platform === 'codex') return path.join(projectRoot, '.agents', 'skills');
|
|
147
150
|
if (platform === 'pi') return path.join(projectRoot, '.pi', 'skills');
|
|
148
151
|
if (platform === 'cursor') return path.join(projectRoot, '.cursor', 'skills');
|
|
152
|
+
if (platform === 'antigravity') return path.join(projectRoot, '.agents', 'plugins', 'prizmkit', 'skills');
|
|
149
153
|
return path.join(projectRoot, '.claude', 'skills');
|
|
150
154
|
}
|
|
151
155
|
|
package/src/prompts.js
CHANGED
|
@@ -37,7 +37,7 @@ export function __resetAiCliPromptsForTests() {
|
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
/**
|
|
40
|
-
* Select target platforms (codebuddy, claude, codex, pi, cursor).
|
|
40
|
+
* Select target platforms (codebuddy, claude, codex, pi, cursor, antigravity).
|
|
41
41
|
* @param {string} currentPlatform - current platform value
|
|
42
42
|
* @param {Object} detected - detected environment info (e.g., { cbc: true, claude: false })
|
|
43
43
|
* @returns {Promise<string>} canonical comma-separated platform ids
|
|
@@ -67,6 +67,10 @@ export async function selectPlatform(currentPlatform, detected = {}) {
|
|
|
67
67
|
id: 'cursor',
|
|
68
68
|
name: `Cursor (.cursor/skills + .cursor/rules + .cursor/hooks.json)${detected.cursor ? chalk.green(' ← 已检测到 agent') : ''}`,
|
|
69
69
|
},
|
|
70
|
+
{
|
|
71
|
+
id: 'antigravity',
|
|
72
|
+
name: `Antigravity (.agents/plugins/prizmkit/)${detected.antigravity ? chalk.green(' ← 已检测到 agy') : ''}`,
|
|
73
|
+
},
|
|
70
74
|
];
|
|
71
75
|
const selected = await selectPlatformPrompt({
|
|
72
76
|
message: '选择目标平台 (决定安装的目录结构,可多选):',
|
|
@@ -89,7 +93,7 @@ export async function selectPlatform(currentPlatform, detected = {}) {
|
|
|
89
93
|
}
|
|
90
94
|
|
|
91
95
|
/**
|
|
92
|
-
* Select AI CLI command (cbc, claude, codex, pi, agent, custom, or skip).
|
|
96
|
+
* Select AI CLI command (cbc, claude, codex, pi, agent, agy, custom, or skip).
|
|
93
97
|
* @param {string} currentCommand - current AI CLI command
|
|
94
98
|
* @param {Object} detected - detected environment info
|
|
95
99
|
* @returns {Promise<string>} - known command, custom string, or ''
|
|
@@ -116,6 +120,10 @@ export async function selectAiCli(currentCommand, detected = {}) {
|
|
|
116
120
|
name: `agent — Cursor Agent CLI${detected.cursor ? chalk.green(' ✓ 已验证') : chalk.gray(' (未检测到或身份未验证)')}`,
|
|
117
121
|
value: 'agent',
|
|
118
122
|
},
|
|
123
|
+
{
|
|
124
|
+
name: `agy — Antigravity CLI${detected.antigravity ? chalk.green(' ✓ 已安装') : chalk.gray(' (未检测到)')}`,
|
|
125
|
+
value: 'agy',
|
|
126
|
+
},
|
|
119
127
|
{
|
|
120
128
|
name: '自定义 — 输入其他命令',
|
|
121
129
|
value: '__custom__',
|
|
@@ -126,7 +134,7 @@ export async function selectAiCli(currentCommand, detected = {}) {
|
|
|
126
134
|
},
|
|
127
135
|
];
|
|
128
136
|
|
|
129
|
-
const knownCliValues = ['cbc', 'claude', 'codex', 'pi', 'agent'];
|
|
137
|
+
const knownCliValues = ['cbc', 'claude', 'codex', 'pi', 'agent', 'agy'];
|
|
130
138
|
const cliDefault = knownCliValues.includes(currentCommand)
|
|
131
139
|
? currentCommand
|
|
132
140
|
: (currentCommand ? '__custom__' : (detected.suggestedCli || ''));
|