@blulotus/trellis 0.7.0 → 0.7.2
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/README.md +2 -2
- package/dist/cli/index.js +2 -29
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/init.d.ts +0 -22
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +5 -12
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/mem.d.ts +2 -2
- package/dist/commands/mem.d.ts.map +1 -1
- package/dist/commands/mem.js +7 -40
- package/dist/commands/mem.js.map +1 -1
- package/dist/commands/uninstall.d.ts +1 -1
- package/dist/commands/uninstall.d.ts.map +1 -1
- package/dist/commands/uninstall.js +4 -34
- package/dist/commands/uninstall.js.map +1 -1
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +2 -28
- package/dist/commands/update.js.map +1 -1
- package/dist/configurators/index.d.ts.map +1 -1
- package/dist/configurators/index.js +7 -73
- package/dist/configurators/index.js.map +1 -1
- package/dist/configurators/shared.d.ts +18 -70
- package/dist/configurators/shared.d.ts.map +1 -1
- package/dist/configurators/shared.js +20 -299
- package/dist/configurators/shared.js.map +1 -1
- package/dist/configurators/workflow.d.ts +0 -14
- package/dist/configurators/workflow.d.ts.map +1 -1
- package/dist/configurators/workflow.js +1 -37
- package/dist/configurators/workflow.js.map +1 -1
- package/dist/migrations/manifests/0.1.9.json +0 -12
- package/dist/migrations/manifests/0.2.14.json +0 -84
- package/dist/migrations/manifests/0.3.0-beta.0.json +0 -87
- package/dist/migrations/manifests/0.3.4.json +1 -13
- package/dist/migrations/manifests/0.4.0-beta.1.json +24 -176
- package/dist/migrations/manifests/0.5.0-beta.0.json +67 -1203
- package/dist/migrations/manifests/0.5.0-beta.15.json +0 -96
- package/dist/migrations/manifests/0.5.0-beta.5.json +0 -168
- package/dist/migrations/manifests/0.5.0-beta.9.json +0 -20
- package/dist/migrations/manifests/0.6.0-beta.23.json +0 -66
- package/dist/migrations/manifests/0.6.3.json +1 -16
- package/dist/migrations/manifests/0.6.6.json +1 -9
- package/dist/migrations/manifests/0.7.0.json +9 -0
- package/dist/migrations/manifests/0.7.1.json +9 -0
- package/dist/migrations/manifests/0.7.2.json +9 -0
- package/dist/migrations/manifests/0.8.0.json +9 -0
- package/dist/templates/codex/hooks/session-start.py +37 -13
- package/dist/templates/codex/hooks.json +5 -0
- package/dist/templates/common/bundled-skills/trellis-meta/SKILL.md +5 -5
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-agents.md +0 -10
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-hooks.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-skills-or-commands.md +1 -13
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/overview.md +2 -2
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/bundled-skills.md +9 -28
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/generated-files.md +5 -5
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/overview.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/agents.md +1 -17
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/hooks-and-settings.md +4 -12
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/overview.md +6 -6
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/platform-map.md +5 -75
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/skills-and-commands.md +0 -16
- package/dist/templates/common/bundled-skills/trellis-session-insight/SKILL.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-session-insight/references/cli-quick-reference.md +2 -3
- package/dist/templates/common/commands/continue.md +24 -4
- package/dist/templates/common/commands/finish-work.md +19 -9
- package/dist/templates/common/commands/start.md +38 -29
- package/dist/templates/extract.d.ts +0 -10
- package/dist/templates/extract.d.ts.map +1 -1
- package/dist/templates/extract.js +0 -24
- package/dist/templates/extract.js.map +1 -1
- package/dist/templates/markdown/spec/guides/code-reuse-thinking-guide.md.txt +7 -9
- package/dist/templates/markdown/spec/guides/cross-layer-thinking-guide.md.txt +4 -8
- package/dist/templates/markdown/spec/guides/cross-platform-thinking-guide.md.txt +5 -5
- package/dist/templates/shared-hooks/index.d.ts +11 -43
- package/dist/templates/shared-hooks/index.d.ts.map +1 -1
- package/dist/templates/shared-hooks/index.js +9 -86
- package/dist/templates/shared-hooks/index.js.map +1 -1
- package/dist/templates/shared-hooks/inject-spec-context.py +1 -1
- package/dist/templates/shared-hooks/inject-subagent-context.py +23 -85
- package/dist/templates/shared-hooks/inject-workflow-state.py +56 -86
- package/dist/templates/shared-hooks/session-start.py +76 -98
- package/dist/templates/trellis/config.yaml +8 -8
- package/dist/templates/trellis/index.d.ts +1 -4
- package/dist/templates/trellis/index.d.ts.map +1 -1
- package/dist/templates/trellis/index.js +1 -5
- package/dist/templates/trellis/index.js.map +1 -1
- package/dist/templates/trellis/scripts/add_session.py +12 -11
- package/dist/templates/trellis/scripts/common/__init__.py +2 -0
- package/dist/templates/trellis/scripts/common/active_task.py +80 -152
- package/dist/templates/trellis/scripts/common/config.py +7 -7
- package/dist/templates/trellis/scripts/common/git_context.py +1 -1
- package/dist/templates/trellis/scripts/common/session_context.py +2 -2
- package/dist/templates/trellis/scripts/common/spec_inject.py +2 -2
- package/dist/templates/trellis/scripts/common/task_store.py +8 -28
- package/dist/templates/trellis/scripts/common/workflow_phase.py +4 -8
- package/dist/templates/trellis/scripts/get_context.py +2 -2
- package/dist/templates/trellis/scripts/init_developer.py +1 -1
- package/dist/templates/trellis/scripts/task.py +90 -57
- package/dist/templates/trellis/workflow.md +44 -66
- package/dist/types/ai-tools.d.ts +10 -10
- package/dist/types/ai-tools.d.ts.map +1 -1
- package/dist/types/ai-tools.js +3 -434
- package/dist/types/ai-tools.js.map +1 -1
- package/dist/utils/uninstall-scrubbers.d.ts +3 -18
- package/dist/utils/uninstall-scrubbers.d.ts.map +1 -1
- package/dist/utils/uninstall-scrubbers.js +24 -154
- package/dist/utils/uninstall-scrubbers.js.map +1 -1
- package/package.json +2 -2
- package/dist/configurators/antigravity.d.ts +0 -7
- package/dist/configurators/antigravity.d.ts.map +0 -1
- package/dist/configurators/antigravity.js +0 -11
- package/dist/configurators/antigravity.js.map +0 -1
- package/dist/configurators/codebuddy.d.ts +0 -10
- package/dist/configurators/codebuddy.d.ts.map +0 -1
- package/dist/configurators/codebuddy.js +0 -24
- package/dist/configurators/codebuddy.js.map +0 -1
- package/dist/configurators/copilot.d.ts +0 -14
- package/dist/configurators/copilot.d.ts.map +0 -1
- package/dist/configurators/copilot.js +0 -46
- package/dist/configurators/copilot.js.map +0 -1
- package/dist/configurators/cursor.d.ts +0 -10
- package/dist/configurators/cursor.d.ts.map +0 -1
- package/dist/configurators/cursor.js +0 -23
- package/dist/configurators/cursor.js.map +0 -1
- package/dist/configurators/devin.d.ts +0 -8
- package/dist/configurators/devin.d.ts.map +0 -1
- package/dist/configurators/devin.js +0 -12
- package/dist/configurators/devin.js.map +0 -1
- package/dist/configurators/droid.d.ts +0 -10
- package/dist/configurators/droid.d.ts.map +0 -1
- package/dist/configurators/droid.js +0 -24
- package/dist/configurators/droid.js.map +0 -1
- package/dist/configurators/dsh.d.ts +0 -26
- package/dist/configurators/dsh.d.ts.map +0 -1
- package/dist/configurators/dsh.js +0 -76
- package/dist/configurators/dsh.js.map +0 -1
- package/dist/configurators/gemini.d.ts +0 -18
- package/dist/configurators/gemini.d.ts.map +0 -1
- package/dist/configurators/gemini.js +0 -39
- package/dist/configurators/gemini.js.map +0 -1
- package/dist/configurators/grok.d.ts +0 -17
- package/dist/configurators/grok.d.ts.map +0 -1
- package/dist/configurators/grok.js +0 -38
- package/dist/configurators/grok.js.map +0 -1
- package/dist/configurators/kilo.d.ts +0 -7
- package/dist/configurators/kilo.d.ts.map +0 -1
- package/dist/configurators/kilo.js +0 -11
- package/dist/configurators/kilo.js.map +0 -1
- package/dist/configurators/kimi.d.ts +0 -26
- package/dist/configurators/kimi.d.ts.map +0 -1
- package/dist/configurators/kimi.js +0 -74
- package/dist/configurators/kimi.js.map +0 -1
- package/dist/configurators/kiro.d.ts +0 -11
- package/dist/configurators/kiro.d.ts.map +0 -1
- package/dist/configurators/kiro.js +0 -30
- package/dist/configurators/kiro.js.map +0 -1
- package/dist/configurators/omp.d.ts +0 -6
- package/dist/configurators/omp.d.ts.map +0 -1
- package/dist/configurators/omp.js +0 -28
- package/dist/configurators/omp.js.map +0 -1
- package/dist/configurators/opencode.d.ts +0 -5
- package/dist/configurators/opencode.d.ts.map +0 -1
- package/dist/configurators/opencode.js +0 -84
- package/dist/configurators/opencode.js.map +0 -1
- package/dist/configurators/pi.d.ts +0 -5
- package/dist/configurators/pi.d.ts.map +0 -1
- package/dist/configurators/pi.js +0 -39
- package/dist/configurators/pi.js.map +0 -1
- package/dist/configurators/qoder.d.ts +0 -12
- package/dist/configurators/qoder.d.ts.map +0 -1
- package/dist/configurators/qoder.js +0 -30
- package/dist/configurators/qoder.js.map +0 -1
- package/dist/configurators/reasonix.d.ts +0 -17
- package/dist/configurators/reasonix.d.ts.map +0 -1
- package/dist/configurators/reasonix.js +0 -37
- package/dist/configurators/reasonix.js.map +0 -1
- package/dist/configurators/snow.d.ts +0 -25
- package/dist/configurators/snow.d.ts.map +0 -1
- package/dist/configurators/snow.js +0 -69
- package/dist/configurators/snow.js.map +0 -1
- package/dist/configurators/trae.d.ts +0 -16
- package/dist/configurators/trae.d.ts.map +0 -1
- package/dist/configurators/trae.js +0 -34
- package/dist/configurators/trae.js.map +0 -1
- package/dist/configurators/zcode.d.ts +0 -23
- package/dist/configurators/zcode.d.ts.map +0 -1
- package/dist/configurators/zcode.js +0 -63
- package/dist/configurators/zcode.js.map +0 -1
- package/dist/templates/codebuddy/agents/trellis-check.md +0 -115
- package/dist/templates/codebuddy/agents/trellis-implement.md +0 -115
- package/dist/templates/codebuddy/agents/trellis-research.md +0 -137
- package/dist/templates/codebuddy/index.d.ts +0 -15
- package/dist/templates/codebuddy/index.d.ts.map +0 -1
- package/dist/templates/codebuddy/index.js +0 -15
- package/dist/templates/codebuddy/index.js.map +0 -1
- package/dist/templates/codebuddy/settings.json +0 -69
- package/dist/templates/copilot/copilot-instructions.md +0 -11
- package/dist/templates/copilot/hooks/session-start.py +0 -564
- package/dist/templates/copilot/hooks.json +0 -19
- package/dist/templates/copilot/index.d.ts +0 -28
- package/dist/templates/copilot/index.d.ts.map +0 -1
- package/dist/templates/copilot/index.js +0 -61
- package/dist/templates/copilot/index.js.map +0 -1
- package/dist/templates/copilot/prompts/before-dev.prompt.md +0 -39
- package/dist/templates/copilot/prompts/brainstorm.prompt.md +0 -173
- package/dist/templates/copilot/prompts/break-loop.prompt.md +0 -129
- package/dist/templates/copilot/prompts/check-cross-layer.prompt.md +0 -170
- package/dist/templates/copilot/prompts/check.prompt.md +0 -110
- package/dist/templates/copilot/prompts/create-command.prompt.md +0 -116
- package/dist/templates/copilot/prompts/finish-work.prompt.md +0 -99
- package/dist/templates/copilot/prompts/integrate-skill.prompt.md +0 -223
- package/dist/templates/copilot/prompts/onboard.prompt.md +0 -362
- package/dist/templates/copilot/prompts/parallel.prompt.md +0 -204
- package/dist/templates/copilot/prompts/record-session.prompt.md +0 -66
- package/dist/templates/copilot/prompts/start.prompt.md +0 -63
- package/dist/templates/copilot/prompts/update-spec.prompt.md +0 -358
- package/dist/templates/cursor/agents/trellis-check.md +0 -114
- package/dist/templates/cursor/agents/trellis-implement.md +0 -114
- package/dist/templates/cursor/agents/trellis-research.md +0 -136
- package/dist/templates/cursor/hooks.json +0 -24
- package/dist/templates/cursor/index.d.ts +0 -13
- package/dist/templates/cursor/index.d.ts.map +0 -1
- package/dist/templates/cursor/index.js +0 -13
- package/dist/templates/cursor/index.js.map +0 -1
- package/dist/templates/droid/droids/trellis-check.md +0 -107
- package/dist/templates/droid/droids/trellis-implement.md +0 -107
- package/dist/templates/droid/droids/trellis-research.md +0 -137
- package/dist/templates/droid/index.d.ts +0 -15
- package/dist/templates/droid/index.d.ts.map +0 -1
- package/dist/templates/droid/index.js +0 -15
- package/dist/templates/droid/index.js.map +0 -1
- package/dist/templates/droid/settings.json +0 -69
- package/dist/templates/dsh/DSH.md +0 -80
- package/dist/templates/dsh/agents/trellis-check.md +0 -99
- package/dist/templates/dsh/agents/trellis-implement.md +0 -106
- package/dist/templates/dsh/agents/trellis-research.md +0 -134
- package/dist/templates/dsh/index.d.ts +0 -22
- package/dist/templates/dsh/index.d.ts.map +0 -1
- package/dist/templates/dsh/index.js +0 -27
- package/dist/templates/dsh/index.js.map +0 -1
- package/dist/templates/gemini/agents/trellis-check.md +0 -107
- package/dist/templates/gemini/agents/trellis-implement.md +0 -107
- package/dist/templates/gemini/agents/trellis-research.md +0 -136
- package/dist/templates/gemini/index.d.ts +0 -13
- package/dist/templates/gemini/index.d.ts.map +0 -1
- package/dist/templates/gemini/index.js +0 -13
- package/dist/templates/gemini/index.js.map +0 -1
- package/dist/templates/gemini/settings.json +0 -40
- package/dist/templates/grok/agents/trellis-check.md +0 -106
- package/dist/templates/grok/agents/trellis-implement.md +0 -121
- package/dist/templates/grok/agents/trellis-research.md +0 -146
- package/dist/templates/grok/index.d.ts +0 -16
- package/dist/templates/grok/index.d.ts.map +0 -1
- package/dist/templates/grok/index.js +0 -19
- package/dist/templates/grok/index.js.map +0 -1
- package/dist/templates/kimi/agents/trellis-check.md +0 -104
- package/dist/templates/kimi/agents/trellis-implement.md +0 -120
- package/dist/templates/kimi/agents/trellis-research.md +0 -144
- package/dist/templates/kimi/index.d.ts +0 -20
- package/dist/templates/kimi/index.d.ts.map +0 -1
- package/dist/templates/kimi/index.js +0 -23
- package/dist/templates/kimi/index.js.map +0 -1
- package/dist/templates/kiro/agents/trellis-check.json +0 -26
- package/dist/templates/kiro/agents/trellis-implement.json +0 -26
- package/dist/templates/kiro/agents/trellis-research.json +0 -30
- package/dist/templates/kiro/agents/trellis.json +0 -34
- package/dist/templates/kiro/hooks/trellis-workflow-state.kiro.hook +0 -14
- package/dist/templates/kiro/index.d.ts +0 -32
- package/dist/templates/kiro/index.d.ts.map +0 -1
- package/dist/templates/kiro/index.js +0 -28
- package/dist/templates/kiro/index.js.map +0 -1
- package/dist/templates/omp/agents/trellis-check.md +0 -41
- package/dist/templates/omp/agents/trellis-implement.md +0 -55
- package/dist/templates/omp/agents/trellis-research.md +0 -30
- package/dist/templates/omp/extensions/trellis/index.ts.txt +0 -592
- package/dist/templates/omp/index.d.ts +0 -4
- package/dist/templates/omp/index.d.ts.map +0 -1
- package/dist/templates/omp/index.js +0 -9
- package/dist/templates/omp/index.js.map +0 -1
- package/dist/templates/opencode/agents/trellis-check.md +0 -122
- package/dist/templates/opencode/agents/trellis-implement.md +0 -123
- package/dist/templates/opencode/agents/trellis-research.md +0 -145
- package/dist/templates/opencode/lib/context-visibility.js +0 -86
- package/dist/templates/opencode/lib/session-utils.js +0 -526
- package/dist/templates/opencode/lib/trellis-context.js +0 -627
- package/dist/templates/opencode/package.json +0 -5
- package/dist/templates/opencode/plugins/inject-spec-context.js +0 -121
- package/dist/templates/opencode/plugins/inject-subagent-context.js +0 -569
- package/dist/templates/opencode/plugins/inject-workflow-state.js +0 -340
- package/dist/templates/opencode/plugins/session-start.js +0 -74
- package/dist/templates/pi/agents/trellis-check.md +0 -37
- package/dist/templates/pi/agents/trellis-implement.md +0 -52
- package/dist/templates/pi/agents/trellis-research.md +0 -25
- package/dist/templates/pi/extensions/trellis/index.ts.txt +0 -2033
- package/dist/templates/pi/index.d.ts +0 -5
- package/dist/templates/pi/index.d.ts.map +0 -1
- package/dist/templates/pi/index.js +0 -12
- package/dist/templates/pi/index.js.map +0 -1
- package/dist/templates/pi/settings.json +0 -9
- package/dist/templates/qoder/agents/trellis-check.md +0 -108
- package/dist/templates/qoder/agents/trellis-implement.md +0 -108
- package/dist/templates/qoder/agents/trellis-research.md +0 -137
- package/dist/templates/qoder/index.d.ts +0 -15
- package/dist/templates/qoder/index.d.ts.map +0 -1
- package/dist/templates/qoder/index.js +0 -15
- package/dist/templates/qoder/index.js.map +0 -1
- package/dist/templates/qoder/settings.json +0 -59
- package/dist/templates/reasonix/agents/trellis-check.md +0 -36
- package/dist/templates/reasonix/agents/trellis-implement.md +0 -51
- package/dist/templates/reasonix/index.d.ts +0 -13
- package/dist/templates/reasonix/index.d.ts.map +0 -1
- package/dist/templates/reasonix/index.js +0 -16
- package/dist/templates/reasonix/index.js.map +0 -1
- package/dist/templates/shared-hooks/inject-shell-session-context.py +0 -292
- package/dist/templates/snow/SNOW.md +0 -86
- package/dist/templates/snow/agents/trellis-check.md +0 -136
- package/dist/templates/snow/agents/trellis-implement.md +0 -158
- package/dist/templates/snow/agents/trellis-research.md +0 -114
- package/dist/templates/snow/hooks/beforeSubAgentStart.json +0 -15
- package/dist/templates/snow/hooks/onSessionStart.json +0 -15
- package/dist/templates/snow/hooks/onUserMessage.json +0 -15
- package/dist/templates/snow/hooks/write-trellis-context.py +0 -644
- package/dist/templates/snow/index.d.ts +0 -26
- package/dist/templates/snow/index.d.ts.map +0 -1
- package/dist/templates/snow/index.js +0 -36
- package/dist/templates/snow/index.js.map +0 -1
- package/dist/templates/trae/agents/trellis-check.md +0 -108
- package/dist/templates/trae/agents/trellis-implement.md +0 -108
- package/dist/templates/trae/agents/trellis-research.md +0 -137
- package/dist/templates/trae/hooks.json +0 -39
- package/dist/templates/trae/index.d.ts +0 -15
- package/dist/templates/trae/index.d.ts.map +0 -1
- package/dist/templates/trae/index.js +0 -15
- package/dist/templates/trae/index.js.map +0 -1
- package/dist/templates/trellis/gitattributes.txt +0 -9
- package/dist/templates/trellis/scripts/common/cli_adapter.py +0 -982
- package/dist/templates/zcode/agents/trellis-check.md +0 -110
- package/dist/templates/zcode/agents/trellis-implement.md +0 -116
- package/dist/templates/zcode/agents/trellis-research.md +0 -133
- package/dist/templates/zcode/config.json +0 -52
- package/dist/templates/zcode/index.d.ts +0 -25
- package/dist/templates/zcode/index.d.ts.map +0 -1
- package/dist/templates/zcode/index.js +0 -29
- package/dist/templates/zcode/index.js.map +0 -1
|
@@ -2,7 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
Wrap up the current session: archive the active task (and any other completed-but-unarchived tasks the user wants to clean up) and record the session journal. Code commits are NOT done here — those happen in workflow Phase 3.4 before you invoke this command.
|
|
4
4
|
|
|
5
|
-
## Step 1:
|
|
5
|
+
## Step 1: Engage this session
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
{{PYTHON_CMD}} ./.trellis/scripts/task.py engage
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
Context injection is opt-in, so this is a no-op when the session already ran an entry point and the step that makes the rest of this command see the active task when it did not.
|
|
12
|
+
|
|
13
|
+
If this exits non-zero, **stop and report it** — without session identity the active-task pointer cannot be resolved and Step 3 would archive the wrong thing or nothing.
|
|
14
|
+
|
|
15
|
+
## Step 2: Survey current state
|
|
6
16
|
|
|
7
17
|
```bash
|
|
8
18
|
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py --mode record
|
|
@@ -12,11 +22,11 @@ This prints:
|
|
|
12
22
|
|
|
13
23
|
- **My active tasks** — review whether any besides the current one are actually done (code merged, AC met) and should be archived this round.
|
|
14
24
|
- **Git status** — quick visual on what's dirty.
|
|
15
|
-
- **Recent commits** — you'll need their hashes in Step
|
|
25
|
+
- **Recent commits** — you'll need their hashes in Step 5 for `--commit`.
|
|
16
26
|
|
|
17
|
-
If `--mode record` surfaces other completed tasks not tied to the current session, surface them to the user with a one-shot confirmation: "These N tasks look done — archive them too in this round? [y/N]". Default is no; the current active task is always archived in Step
|
|
27
|
+
If `--mode record` surfaces other completed tasks not tied to the current session, surface them to the user with a one-shot confirmation: "These N tasks look done — archive them too in this round? [y/N]". Default is no; the current active task is always archived in Step 4 regardless.
|
|
18
28
|
|
|
19
|
-
## Step
|
|
29
|
+
## Step 3: Sanity check — classify dirty paths
|
|
20
30
|
|
|
21
31
|
Run:
|
|
22
32
|
|
|
@@ -38,21 +48,21 @@ Then route:
|
|
|
38
48
|
> "Working tree has uncommitted code changes from this task: `<list>`. Return to workflow Phase 3.4 to commit them before running `{{CMD_REF:finish-work}}`."
|
|
39
49
|
|
|
40
50
|
Do NOT run `git commit` here. Do NOT prompt the user to commit. The user goes back to Phase 3.4 and the AI drives the batched commit there.
|
|
41
|
-
- **All remaining paths look unrelated** (other parallel-window work) — report them once and continue to Step
|
|
51
|
+
- **All remaining paths look unrelated** (other parallel-window work) — report them once and continue to Step 4:
|
|
42
52
|
> "FYI, dirty files outside this task's scope — leaving them for the other window: `<list>`."
|
|
43
53
|
- **Genuinely unsure** — ask the user once: "Are `<list>` this task's work I forgot to commit, or another window's? (commit / ignore)" — then route per their answer.
|
|
44
54
|
|
|
45
|
-
## Step
|
|
55
|
+
## Step 4: Archive task(s)
|
|
46
56
|
|
|
47
57
|
```bash
|
|
48
58
|
{{PYTHON_CMD}} ./.trellis/scripts/task.py archive <task-name>
|
|
49
59
|
```
|
|
50
60
|
|
|
51
|
-
At minimum: the current active task (if any). Plus any extra tasks the user confirmed in Step
|
|
61
|
+
At minimum: the current active task (if any). Plus any extra tasks the user confirmed in Step 2. Each archive produces a `chore(task): archive ...` commit via the script's auto-commit.
|
|
52
62
|
|
|
53
63
|
If there is no active task and the user did not confirm any cleanup archives, skip this step.
|
|
54
64
|
|
|
55
|
-
## Step
|
|
65
|
+
## Step 5: Record session journal
|
|
56
66
|
|
|
57
67
|
```bash
|
|
58
68
|
{{PYTHON_CMD}} ./.trellis/scripts/add_session.py \
|
|
@@ -61,6 +71,6 @@ If there is no active task and the user did not confirm any cleanup archives, sk
|
|
|
61
71
|
--summary "Brief summary"
|
|
62
72
|
```
|
|
63
73
|
|
|
64
|
-
Use the work-commit hashes produced in Phase 3.4 (visible in Step
|
|
74
|
+
Use the work-commit hashes produced in Phase 3.4 (visible in Step 2's `Recent commits` list, or via `git log --oneline`) for `--commit`. Do not include the archive commit hashes from Step 4. This produces a `chore: record journal` commit.
|
|
65
75
|
|
|
66
76
|
Final git log order: `<work commits from 3.4>` → `chore(task): archive ...` (one or more) → `chore: record journal`.
|
|
@@ -1,59 +1,68 @@
|
|
|
1
|
-
# Start
|
|
1
|
+
# Start Trellis Task
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Create a Trellis task for the request the user just made, then plan it. Invoking this **is** the explicit request for a task — do not ask whether the work warrants one.
|
|
4
|
+
|
|
5
|
+
Context injection is opt-in: until Step 1 runs, this session receives no Trellis context at all. Run the steps in order.
|
|
4
6
|
|
|
5
7
|
---
|
|
6
8
|
|
|
7
|
-
## Step 1:
|
|
8
|
-
Identity, git status, current task, active tasks, journal location.
|
|
9
|
+
## Step 1: Engage this session
|
|
9
10
|
|
|
10
11
|
```bash
|
|
11
|
-
{{PYTHON_CMD}} ./.trellis/scripts/
|
|
12
|
+
{{PYTHON_CMD}} ./.trellis/scripts/task.py engage
|
|
12
13
|
```
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
Marks this session as Trellis-managed, which turns on the per-turn workflow breadcrumb and re-injection after `/clear` or `/compact`.
|
|
16
|
+
|
|
17
|
+
If this exits non-zero, **stop and report it**. Without the flag every later phase runs unguided, and the planning and commit gates will not be enforced.
|
|
15
18
|
|
|
16
|
-
## Step 2:
|
|
17
|
-
Compact Phase Index, request triage rules, planning artifact contract, and the step-detail command.
|
|
19
|
+
## Step 2: Load the workflow
|
|
18
20
|
|
|
19
21
|
```bash
|
|
22
|
+
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py
|
|
20
23
|
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py --mode phase
|
|
21
24
|
```
|
|
22
25
|
|
|
23
|
-
|
|
26
|
+
The first prints identity, git state, and any already-active tasks. The second prints the Phase Index, the planning artifact contract, and the red-evidence gate.
|
|
27
|
+
|
|
28
|
+
If the first output includes a line beginning `Trellis update available:`, relay that line verbatim to the user.
|
|
29
|
+
|
|
30
|
+
If it reports a task already active in this session, do not create a second one — switch to {{CMD_REF:continue}}.
|
|
24
31
|
|
|
25
|
-
## Step 3:
|
|
26
|
-
Discover packages + spec layers, then read each relevant index file.
|
|
32
|
+
## Step 3: Create the task
|
|
27
33
|
|
|
28
34
|
```bash
|
|
29
|
-
{{PYTHON_CMD}} ./.trellis/scripts/
|
|
30
|
-
cat .trellis/spec/guides/index.md
|
|
31
|
-
cat .trellis/spec/<package>/<layer>/index.md # for each relevant layer
|
|
35
|
+
{{PYTHON_CMD}} ./.trellis/scripts/task.py create "<task title>" --slug <name> --meta kind=<bug|feature|chore>
|
|
32
36
|
```
|
|
33
37
|
|
|
34
|
-
|
|
38
|
+
- `--slug` is the human-readable name only; the `MM-DD-` prefix is added for you.
|
|
39
|
+
- `--meta kind=` selects the red-evidence gate: `bug` needs an executed repro with red output, `feature` needs a user-confirmed test-seam list, `chore` is exempt. **Never guess the kind** — if the request does not make it unambiguous, ask the user before running the command.
|
|
40
|
+
- Run only `create`. Do not run `task.py start`; that flips status to `in_progress` and skips the planning gate. `start` belongs to Phase 1.4, after the artifacts are reviewed.
|
|
35
41
|
|
|
36
|
-
|
|
37
|
-
From Step 1 you know the current task and status. Check the task directory:
|
|
42
|
+
Creating the task is not approval to implement.
|
|
38
43
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
```
|
|
45
|
-
- **No active task** → work inline. Do not ask whether to create a Trellis task; create one only when the user explicitly asks for it.
|
|
44
|
+
## Step 4: Plan it
|
|
45
|
+
|
|
46
|
+
Load the `trellis-brainstorm` skill and align on requirements with the user.
|
|
47
|
+
|
|
48
|
+
Every task needs `prd.md`, `design.md`, and `implement.md` before `task.py start` — there is no PRD-only tier.
|
|
46
49
|
|
|
47
50
|
---
|
|
48
51
|
|
|
49
|
-
##
|
|
52
|
+
## Where this leaves you
|
|
53
|
+
|
|
54
|
+
You are in Phase 1 with status `planning`. From here the per-turn breadcrumb carries the phase rules; step detail is available with:
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py --mode phase --step <X.Y> --platform {{CLI_FLAG}}
|
|
58
|
+
```
|
|
50
59
|
|
|
51
60
|
| User intent | Skill |
|
|
52
61
|
|---|---|
|
|
53
|
-
|
|
|
62
|
+
| Requirements unclear / new feature | `trellis-brainstorm` |
|
|
54
63
|
| About to write code | `trellis-before-dev` |
|
|
55
64
|
| Done coding / quality check | `trellis-check` |
|
|
56
|
-
| Stuck / fixed same bug
|
|
57
|
-
| Learned something worth
|
|
65
|
+
| Stuck / fixed same bug repeatedly | `trellis-break-loop` |
|
|
66
|
+
| Learned something worth keeping | `trellis-update-spec` |
|
|
58
67
|
|
|
59
|
-
Full rules
|
|
68
|
+
Full rules in `.trellis/workflow.md`.
|
|
@@ -9,16 +9,6 @@ export declare function getTrellisSourcePath(): string;
|
|
|
9
9
|
* Get the path to the claude templates directory (hooks, agents, settings).
|
|
10
10
|
*/
|
|
11
11
|
export declare function getClaudeTemplatePath(): string;
|
|
12
|
-
/**
|
|
13
|
-
* Get the path to the opencode templates directory (agents, plugins, lib).
|
|
14
|
-
*/
|
|
15
|
-
export declare function getOpenCodeTemplatePath(): string;
|
|
16
|
-
/**
|
|
17
|
-
* Get the path to the Pi Agent templates directory (agents, extension, settings).
|
|
18
|
-
*/
|
|
19
|
-
export declare function getPiTemplatePath(): string;
|
|
20
|
-
/** @deprecated Use getPiTemplatePath() instead. */
|
|
21
|
-
export declare function getPiSourcePath(): string;
|
|
22
12
|
/**
|
|
23
13
|
* Read a file from the trellis template directory.
|
|
24
14
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract.d.ts","sourceRoot":"","sources":["../../src/templates/extract.ts"],"names":[],"mappings":"AASA,KAAK,gBAAgB,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,CAAC;AAE5D;;GAEG;AACH,wBAAgB,sBAAsB,IAAI,MAAM,CAQ/C;AAED,wDAAwD;AACxD,wBAAgB,oBAAoB,IAAI,MAAM,CAE7C;AAED;;GAEG;AACH,wBAAgB,qBAAqB,IAAI,MAAM,CAQ9C;AAED;;GAEG;AACH,wBAAgB,
|
|
1
|
+
{"version":3,"file":"extract.d.ts","sourceRoot":"","sources":["../../src/templates/extract.ts"],"names":[],"mappings":"AASA,KAAK,gBAAgB,GAAG,SAAS,GAAG,UAAU,GAAG,UAAU,CAAC;AAE5D;;GAEG;AACH,wBAAgB,sBAAsB,IAAI,MAAM,CAQ/C;AAED,wDAAwD;AACxD,wBAAgB,oBAAoB,IAAI,MAAM,CAE7C;AAED;;GAEG;AACH,wBAAgB,qBAAqB,IAAI,MAAM,CAQ9C;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAI5D;AAED;;GAEG;AACH,wBAAgB,YAAY,CAC1B,QAAQ,EAAE,gBAAgB,EAC1B,QAAQ,EAAE,MAAM,GACf,MAAM,CAGR;AAED,wBAAgB,UAAU,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAEvD;AAED,wBAAgB,YAAY,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM,CAEzD;AAED,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAEpD;AAED;;GAEG;AACH,wBAAsB,cAAc,CAClC,eAAe,EAAE,MAAM,EACvB,QAAQ,EAAE,MAAM,EAChB,OAAO,CAAC,EAAE;IAAE,UAAU,CAAC,EAAE,OAAO,CAAA;CAAE,GACjC,OAAO,CAAC,IAAI,CAAC,CAIf"}
|
|
@@ -29,30 +29,6 @@ export function getClaudeTemplatePath() {
|
|
|
29
29
|
}
|
|
30
30
|
throw new Error("Could not find claude templates directory. Expected at templates/claude/");
|
|
31
31
|
}
|
|
32
|
-
/**
|
|
33
|
-
* Get the path to the opencode templates directory (agents, plugins, lib).
|
|
34
|
-
*/
|
|
35
|
-
export function getOpenCodeTemplatePath() {
|
|
36
|
-
const templatePath = path.join(__dirname, "opencode");
|
|
37
|
-
if (fs.existsSync(templatePath)) {
|
|
38
|
-
return templatePath;
|
|
39
|
-
}
|
|
40
|
-
throw new Error("Could not find opencode templates directory. Expected at templates/opencode/");
|
|
41
|
-
}
|
|
42
|
-
/**
|
|
43
|
-
* Get the path to the Pi Agent templates directory (agents, extension, settings).
|
|
44
|
-
*/
|
|
45
|
-
export function getPiTemplatePath() {
|
|
46
|
-
const templatePath = path.join(__dirname, "pi");
|
|
47
|
-
if (fs.existsSync(templatePath)) {
|
|
48
|
-
return templatePath;
|
|
49
|
-
}
|
|
50
|
-
throw new Error("Could not find pi templates directory. Expected at templates/pi/");
|
|
51
|
-
}
|
|
52
|
-
/** @deprecated Use getPiTemplatePath() instead. */
|
|
53
|
-
export function getPiSourcePath() {
|
|
54
|
-
return getPiTemplatePath();
|
|
55
|
-
}
|
|
56
32
|
/**
|
|
57
33
|
* Read a file from the trellis template directory.
|
|
58
34
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extract.js","sourceRoot":"","sources":["../../src/templates/extract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,SAAS,CAAC;AAC9B,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,EAAE,4BAA4B,EAAE,MAAM,4BAA4B,CAAC;AAE1E,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;AAI3C;;GAEG;AACH,MAAM,UAAU,sBAAsB;IACpC,MAAM,YAAY,GAAG,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;IACrD,IAAI,EAAE,CAAC,UAAU,CAAC,YAAY,CAAC,EAAE,CAAC;QAChC,OAAO,YAAY,CAAC;IACtB,CAAC;IACD,MAAM,IAAI,KAAK,CACb,4EAA4E,CAC7E,CAAC;AACJ,CAAC;AAED,wDAAwD;AACxD,MAAM,UAAU,oBAAoB;IAClC,OAAO,sBAAsB,EAAE,CAAC;AAClC,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,qBAAqB;IACnC,MAAM,YAAY,GAAG,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IACpD,IAAI,EAAE,CAAC,UAAU,CAAC,YAAY,CAAC,EAAE,CAAC;QAChC,OAAO,YAAY,CAAC;IACtB,CAAC;IACD,MAAM,IAAI,KAAK,CACb,0EAA0E,CAC3E,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"extract.js","sourceRoot":"","sources":["../../src/templates/extract.ts"],"names":[],"mappings":"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"}
|
|
@@ -150,23 +150,21 @@ of that replay model.
|
|
|
150
150
|
|
|
151
151
|
**Symptom**: New platform works partially — some methods return Claude defaults instead of platform-specific values. No error is raised.
|
|
152
152
|
|
|
153
|
-
**Example
|
|
153
|
+
**Example**:
|
|
154
154
|
```python
|
|
155
|
-
# BAD: "
|
|
155
|
+
# BAD: a newly added "codex" falls through to else, returns "claude"
|
|
156
156
|
@property
|
|
157
157
|
def cli_name(self) -> str:
|
|
158
|
-
if self.platform == "
|
|
159
|
-
return "
|
|
158
|
+
if self.platform == "claude":
|
|
159
|
+
return "claude"
|
|
160
160
|
else:
|
|
161
|
-
return "claude" #
|
|
161
|
+
return "claude" # codex silently gets "claude"!
|
|
162
162
|
|
|
163
163
|
# GOOD: explicit branch for every platform
|
|
164
164
|
@property
|
|
165
165
|
def cli_name(self) -> str:
|
|
166
|
-
if self.platform == "
|
|
167
|
-
return "
|
|
168
|
-
elif self.platform == "gemini":
|
|
169
|
-
return "gemini"
|
|
166
|
+
if self.platform == "codex":
|
|
167
|
+
return "codex"
|
|
170
168
|
else:
|
|
171
169
|
return "claude"
|
|
172
170
|
```
|
|
@@ -131,10 +131,9 @@ In Trellis, command templates (e.g., `record-session.md`) exist in **multiple pl
|
|
|
131
131
|
|
|
132
132
|
- [ ] Find all platforms with the same command: `find src/templates/*/commands/trellis/ -name "<command>.*"`
|
|
133
133
|
- [ ] Update all platform copies (Markdown `.md` and TOML `.toml`)
|
|
134
|
-
- [ ] For Gemini TOML: adapt line continuations (`\\` vs `\`) and triple-quoted strings
|
|
135
134
|
- [ ] Run `/trellis:check-cross-layer` to verify nothing was missed
|
|
136
135
|
|
|
137
|
-
**Real-world example**: Updated `record-session.md`
|
|
136
|
+
**Real-world example**: Updated `record-session.md` for Claude Code to use `--mode record`, but forgot the Codex copy — caught by cross-layer check.
|
|
138
137
|
|
|
139
138
|
---
|
|
140
139
|
|
|
@@ -185,8 +184,7 @@ release docs, move the 0.6 content to `beta/` and `zh/beta/`, and add a grep
|
|
|
185
184
|
audit for beta markers against the root release tree.
|
|
186
185
|
|
|
187
186
|
**Real-world example**: Codex inline mode changed workflow platform markers from
|
|
188
|
-
`[Codex]`
|
|
189
|
-
`[codex-inline, Kilo, Antigravity, Windsurf]`. Fresh init was correct, but
|
|
187
|
+
`[Codex]` to `[codex-sub-agent]` / `[codex-inline]`. Fresh init was correct, but
|
|
190
188
|
`trellis update` only merged `[workflow-state:*]` blocks and preserved stale
|
|
191
189
|
markers outside those blocks. Result: upgraded projects got new hook scripts
|
|
192
190
|
but old workflow routing, so `get_context.py --mode phase --platform codex`
|
|
@@ -228,10 +226,9 @@ In Trellis, command templates (e.g., `record-session.md`) exist in **multiple pl
|
|
|
228
226
|
|
|
229
227
|
- [ ] Find all platforms with the same command: `find src/templates/*/commands/trellis/ -name "<command>.*"`
|
|
230
228
|
- [ ] Update all platform copies (Markdown `.md` and TOML `.toml`)
|
|
231
|
-
- [ ] For Gemini TOML: adapt line continuations (`\\` vs `\`) and triple-quoted strings
|
|
232
229
|
- [ ] Run `/trellis:check-cross-layer` to verify nothing was missed
|
|
233
230
|
|
|
234
|
-
**Real-world example**: Updated `record-session.md`
|
|
231
|
+
**Real-world example**: Updated `record-session.md` for Claude Code to use `--mode record`, but forgot the Codex copy — caught by cross-layer check.
|
|
235
232
|
|
|
236
233
|
---
|
|
237
234
|
|
|
@@ -255,8 +252,7 @@ against both fresh init and upgrade paths.
|
|
|
255
252
|
- [ ] Update the backend spec that owns the runtime contract
|
|
256
253
|
|
|
257
254
|
**Real-world example**: Codex inline mode changed workflow platform markers from
|
|
258
|
-
`[Codex]`
|
|
259
|
-
`[codex-inline, Kilo, Antigravity, Windsurf]`. Fresh init was correct, but
|
|
255
|
+
`[Codex]` to `[codex-sub-agent]` / `[codex-inline]`. Fresh init was correct, but
|
|
260
256
|
`trellis update` only merged `[workflow-state:*]` blocks and preserved stale
|
|
261
257
|
markers outside those blocks. Result: upgraded projects got new hook scripts
|
|
262
258
|
but old workflow routing, so `get_context.py --mode phase --platform codex`
|
|
@@ -85,7 +85,7 @@ function warnIfPythonTooOld(): void {
|
|
|
85
85
|
}
|
|
86
86
|
```
|
|
87
87
|
|
|
88
|
-
**Rule 5**: Don't assume the Python version the AI CLI uses matches your shell's `python3`. The user's terminal may resolve `python3` → homebrew 3.11, but AI CLI hosts (including enterprise-forked Claude Code
|
|
88
|
+
**Rule 5**: Don't assume the Python version the AI CLI uses matches your shell's `python3`. The user's terminal may resolve `python3` → homebrew 3.11, but AI CLI hosts (including enterprise-forked Claude Code distributions) spawn hook subprocesses with a minimal PATH that resolves `python3` → `/usr/bin/python3` → macOS system 3.9. Distributed templates must either target the lowest plausible version or use `from __future__ import annotations` for PEP 604 syntax. See `cli/backend/script-conventions.md` → **CRITICAL: PEP 604 Annotations Require `from __future__ import annotations`** for the hard rule and audit check.
|
|
89
89
|
|
|
90
90
|
**Rule 6**: When calling Python from Python, use `sys.executable`:
|
|
91
91
|
|
|
@@ -137,7 +137,7 @@ A path string has two distinct roles. **Treat them differently.**
|
|
|
137
137
|
function collectTemplates(): Map<string, string> {
|
|
138
138
|
const files = new Map<string, string>();
|
|
139
139
|
for (const entry of walk(dir)) {
|
|
140
|
-
files.set(path.join(".
|
|
140
|
+
files.set(path.join(".codex", entry), readFile(entry)); // \ on Windows
|
|
141
141
|
}
|
|
142
142
|
return files;
|
|
143
143
|
}
|
|
@@ -148,7 +148,7 @@ import { toPosix } from "../utils/posix.js";
|
|
|
148
148
|
function collectTemplates(): Map<string, string> {
|
|
149
149
|
const files = new Map<string, string>();
|
|
150
150
|
for (const entry of walk(dir)) {
|
|
151
|
-
files.set(toPosix(path.join(".
|
|
151
|
+
files.set(toPosix(path.join(".codex", entry)), readFile(entry));
|
|
152
152
|
}
|
|
153
153
|
return files;
|
|
154
154
|
}
|
|
@@ -340,7 +340,7 @@ result = subprocess.run(
|
|
|
340
340
|
When making platform-related changes, check **all these locations**:
|
|
341
341
|
|
|
342
342
|
### Commands / Skills Sync
|
|
343
|
-
- [ ] New command/skill added to ALL platforms (claude,
|
|
343
|
+
- [ ] New command/skill added to ALL platforms (claude, codex, and any new platform)
|
|
344
344
|
- [ ] Each platform's test file updated with new entry in `EXPECTED_COMMAND_NAMES` / `EXPECTED_SKILL_NAMES`
|
|
345
345
|
- [ ] Platform-integration spec's required command table updated if adding a new required command
|
|
346
346
|
- [ ] Command format matches platform convention (see `platform-integration.md` → Command Format by Platform)
|
|
@@ -388,7 +388,7 @@ Before committing cross-platform code:
|
|
|
388
388
|
|
|
389
389
|
### 7. External Tool API Contracts
|
|
390
390
|
|
|
391
|
-
When integrating with external tools (Claude Code,
|
|
391
|
+
When integrating with external tools (Claude Code, Codex, etc.), their API contracts are **implicit assumptions**.
|
|
392
392
|
|
|
393
393
|
**Rule**: Verify API formats from official documentation, don't guess.
|
|
394
394
|
|
|
@@ -11,62 +11,30 @@ export interface HookScript {
|
|
|
11
11
|
/** Script content — no placeholders, ready to write directly */
|
|
12
12
|
content: string;
|
|
13
13
|
}
|
|
14
|
-
export type SharedHookName = "session-start.py" | "inject-
|
|
15
|
-
export type SharedHookPlatform = "claude" | "
|
|
14
|
+
export type SharedHookName = "session-start.py" | "inject-workflow-state.py" | "inject-subagent-context.py" | "inject-spec-context.py";
|
|
15
|
+
export type SharedHookPlatform = "claude" | "codex";
|
|
16
16
|
/**
|
|
17
17
|
* Which shared hooks each platform actually invokes. Single source of truth
|
|
18
18
|
* for shared-hook distribution — `collectSharedHooks` reads this table, and
|
|
19
19
|
* both `trellis init` and `trellis update` consume the map it returns.
|
|
20
20
|
*
|
|
21
21
|
* Routing rules encoded here:
|
|
22
|
-
* - `session-start.py` — shipped by
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* - `inject-workflow-state.py` —
|
|
26
|
-
*
|
|
27
|
-
* per-turn main-session hooks are excluded.
|
|
22
|
+
* - `session-start.py` — shipped by platforms with a SessionStart hook event.
|
|
23
|
+
* Codex is excluded: it bundles a platform-specific session-start.py under
|
|
24
|
+
* its own template dir.
|
|
25
|
+
* - `inject-workflow-state.py` — platforms with a UserPromptSubmit (or
|
|
26
|
+
* equivalent) per-turn event.
|
|
28
27
|
* - `inject-subagent-context.py` — platforms with native sub-agent context
|
|
29
|
-
* delivery.
|
|
30
|
-
* SubagentStart `additionalContext` event.
|
|
31
|
-
* such as copilot, gemini, qoder, and trae still load context from a
|
|
32
|
-
* self-loading agent profile.
|
|
33
|
-
* - `inject-shell-session-context.py` — platforms with a hook that fires
|
|
34
|
-
* *before* a shell command and receives both the session id and the pending
|
|
35
|
-
* command. That hook is the only channel by which session identity reaches
|
|
36
|
-
* `task.py`, which runs in the shell child: no platform researched exports a
|
|
37
|
-
* session id into that child (2026-08-05 audit of 21 platforms). Declaring a
|
|
38
|
-
* platform here also requires an entry in its own hook config template —
|
|
39
|
-
* `shared-hooks.test.ts` fails the build when the two disagree, because a
|
|
40
|
-
* script on disk that nothing invokes is indistinguishable from success.
|
|
41
|
-
* Kiro is deliberately absent: its two hook surfaces (CLI agent JSON
|
|
42
|
-
* `hooks.{agentSpawn,userPromptSubmit}` and IDE `.kiro.hook` `when.type`)
|
|
43
|
-
* publish no pre-tool trigger, and an unknown key in the agent JSON risks
|
|
44
|
-
* the whole agent failing to load. Settle it by running Kiro and checking
|
|
45
|
-
* its hook trigger list before adding it.
|
|
46
|
-
* - Kiro supports per-turn + spawn hooks on both surfaces (per the official
|
|
47
|
-
* docs https://kiro.dev/docs/cli/hooks/): the CLI custom agent declares
|
|
48
|
-
* `hooks.userPromptSubmit` + `hooks.agentSpawn`, and the IDE declares a
|
|
49
|
-
* `.kiro.hook` with `when.type=promptSubmit`. So Kiro ships
|
|
50
|
-
* `session-start.py` (agentSpawn overview), `inject-workflow-state.py`
|
|
51
|
-
* (per-turn breadcrumb), and `inject-subagent-context.py` (sub-agent
|
|
52
|
-
* spawn). The scripts emit a plain-text Kiro branch — Kiro adds a hook's
|
|
53
|
-
* stdout directly to the conversation context (no JSON envelope).
|
|
28
|
+
* delivery. Claude Code uses a PreToolUse prompt mutation; Codex uses its
|
|
29
|
+
* SubagentStart `additionalContext` event.
|
|
54
30
|
* - `inject-spec-context.py` — path-scoped spec injection. Claude Code uses
|
|
55
|
-
* PostToolUse Read/Edit/Write/MultiEdit; Codex and
|
|
56
|
-
*
|
|
57
|
-
* adapts write/edit/apply_patch calls and blocks a FULL emission once so the
|
|
58
|
-
* model sees the specs before retrying. Class-2 platforms use
|
|
59
|
-
* `get_context.py --mode spec` pull mode instead.
|
|
31
|
+
* PostToolUse Read/Edit/Write/MultiEdit; Codex uses PreToolUse and passes the
|
|
32
|
+
* native apply_patch payload directly.
|
|
60
33
|
* - Claude Code `statusLine` is intentionally not installed by default.
|
|
61
34
|
* Users can add their own statusLine command in `.claude/settings.json`,
|
|
62
35
|
* or opt in to the Trellis one via `trellis init --with-statusline`
|
|
63
36
|
* (installed from `templates/claude/hooks/`, not from this table — no
|
|
64
37
|
* other platform has a statusLine event).
|
|
65
|
-
* - ZCode (3.x) ships a workspace hook config at `.zcode/config.json` covering
|
|
66
|
-
* SessionStart + UserPromptSubmit in the main session, plus PreToolUse for
|
|
67
|
-
* `Agent|Task`. Live probing confirmed `hookSpecificOutput.updatedInput`
|
|
68
|
-
* reaches the sub-agent prompt, so ZCode is class-1 and ships
|
|
69
|
-
* `inject-subagent-context.py`.
|
|
70
38
|
*/
|
|
71
39
|
export declare const SHARED_HOOKS_BY_PLATFORM: Record<SharedHookPlatform, readonly SharedHookName[]>;
|
|
72
40
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/shared-hooks/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAaH,MAAM,WAAW,UAAU;IACzB,0CAA0C;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,gEAAgE;IAChE,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,cAAc,GACtB,kBAAkB,GAClB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/shared-hooks/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAaH,MAAM,WAAW,UAAU;IACzB,0CAA0C;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,gEAAgE;IAChE,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,cAAc,GACtB,kBAAkB,GAClB,0BAA0B,GAC1B,4BAA4B,GAC5B,wBAAwB,CAAC;AAE7B,MAAM,MAAM,kBAAkB,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,wBAAwB,EAAE,MAAM,CAC3C,kBAAkB,EAClB,SAAS,cAAc,EAAE,CAa1B,CAAC;AAEF;;;GAGG;AACH,wBAAgB,oBAAoB,IAAI,UAAU,EAAE,CAWnD;AAED;;;;GAIG;AACH,wBAAgB,+BAA+B,CAC7C,QAAQ,EAAE,kBAAkB,GAC3B,UAAU,EAAE,CAGd"}
|
|
@@ -19,54 +19,22 @@ function readTemplate(relativePath) {
|
|
|
19
19
|
* both `trellis init` and `trellis update` consume the map it returns.
|
|
20
20
|
*
|
|
21
21
|
* Routing rules encoded here:
|
|
22
|
-
* - `session-start.py` — shipped by
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* - `inject-workflow-state.py` —
|
|
26
|
-
*
|
|
27
|
-
* per-turn main-session hooks are excluded.
|
|
22
|
+
* - `session-start.py` — shipped by platforms with a SessionStart hook event.
|
|
23
|
+
* Codex is excluded: it bundles a platform-specific session-start.py under
|
|
24
|
+
* its own template dir.
|
|
25
|
+
* - `inject-workflow-state.py` — platforms with a UserPromptSubmit (or
|
|
26
|
+
* equivalent) per-turn event.
|
|
28
27
|
* - `inject-subagent-context.py` — platforms with native sub-agent context
|
|
29
|
-
* delivery.
|
|
30
|
-
* SubagentStart `additionalContext` event.
|
|
31
|
-
* such as copilot, gemini, qoder, and trae still load context from a
|
|
32
|
-
* self-loading agent profile.
|
|
33
|
-
* - `inject-shell-session-context.py` — platforms with a hook that fires
|
|
34
|
-
* *before* a shell command and receives both the session id and the pending
|
|
35
|
-
* command. That hook is the only channel by which session identity reaches
|
|
36
|
-
* `task.py`, which runs in the shell child: no platform researched exports a
|
|
37
|
-
* session id into that child (2026-08-05 audit of 21 platforms). Declaring a
|
|
38
|
-
* platform here also requires an entry in its own hook config template —
|
|
39
|
-
* `shared-hooks.test.ts` fails the build when the two disagree, because a
|
|
40
|
-
* script on disk that nothing invokes is indistinguishable from success.
|
|
41
|
-
* Kiro is deliberately absent: its two hook surfaces (CLI agent JSON
|
|
42
|
-
* `hooks.{agentSpawn,userPromptSubmit}` and IDE `.kiro.hook` `when.type`)
|
|
43
|
-
* publish no pre-tool trigger, and an unknown key in the agent JSON risks
|
|
44
|
-
* the whole agent failing to load. Settle it by running Kiro and checking
|
|
45
|
-
* its hook trigger list before adding it.
|
|
46
|
-
* - Kiro supports per-turn + spawn hooks on both surfaces (per the official
|
|
47
|
-
* docs https://kiro.dev/docs/cli/hooks/): the CLI custom agent declares
|
|
48
|
-
* `hooks.userPromptSubmit` + `hooks.agentSpawn`, and the IDE declares a
|
|
49
|
-
* `.kiro.hook` with `when.type=promptSubmit`. So Kiro ships
|
|
50
|
-
* `session-start.py` (agentSpawn overview), `inject-workflow-state.py`
|
|
51
|
-
* (per-turn breadcrumb), and `inject-subagent-context.py` (sub-agent
|
|
52
|
-
* spawn). The scripts emit a plain-text Kiro branch — Kiro adds a hook's
|
|
53
|
-
* stdout directly to the conversation context (no JSON envelope).
|
|
28
|
+
* delivery. Claude Code uses a PreToolUse prompt mutation; Codex uses its
|
|
29
|
+
* SubagentStart `additionalContext` event.
|
|
54
30
|
* - `inject-spec-context.py` — path-scoped spec injection. Claude Code uses
|
|
55
|
-
* PostToolUse Read/Edit/Write/MultiEdit; Codex and
|
|
56
|
-
*
|
|
57
|
-
* adapts write/edit/apply_patch calls and blocks a FULL emission once so the
|
|
58
|
-
* model sees the specs before retrying. Class-2 platforms use
|
|
59
|
-
* `get_context.py --mode spec` pull mode instead.
|
|
31
|
+
* PostToolUse Read/Edit/Write/MultiEdit; Codex uses PreToolUse and passes the
|
|
32
|
+
* native apply_patch payload directly.
|
|
60
33
|
* - Claude Code `statusLine` is intentionally not installed by default.
|
|
61
34
|
* Users can add their own statusLine command in `.claude/settings.json`,
|
|
62
35
|
* or opt in to the Trellis one via `trellis init --with-statusline`
|
|
63
36
|
* (installed from `templates/claude/hooks/`, not from this table — no
|
|
64
37
|
* other platform has a statusLine event).
|
|
65
|
-
* - ZCode (3.x) ships a workspace hook config at `.zcode/config.json` covering
|
|
66
|
-
* SessionStart + UserPromptSubmit in the main session, plus PreToolUse for
|
|
67
|
-
* `Agent|Task`. Live probing confirmed `hookSpecificOutput.updatedInput`
|
|
68
|
-
* reaches the sub-agent prompt, so ZCode is class-1 and ships
|
|
69
|
-
* `inject-subagent-context.py`.
|
|
70
38
|
*/
|
|
71
39
|
export const SHARED_HOOKS_BY_PLATFORM = {
|
|
72
40
|
claude: [
|
|
@@ -75,56 +43,11 @@ export const SHARED_HOOKS_BY_PLATFORM = {
|
|
|
75
43
|
"inject-subagent-context.py",
|
|
76
44
|
"inject-spec-context.py",
|
|
77
45
|
],
|
|
78
|
-
cursor: [
|
|
79
|
-
"session-start.py",
|
|
80
|
-
"inject-shell-session-context.py",
|
|
81
|
-
"inject-subagent-context.py",
|
|
82
|
-
],
|
|
83
46
|
codex: [
|
|
84
47
|
"inject-workflow-state.py",
|
|
85
48
|
"inject-subagent-context.py",
|
|
86
49
|
"inject-spec-context.py",
|
|
87
50
|
],
|
|
88
|
-
opencode: ["inject-spec-context.py"],
|
|
89
|
-
gemini: [
|
|
90
|
-
"session-start.py",
|
|
91
|
-
"inject-shell-session-context.py",
|
|
92
|
-
"inject-workflow-state.py",
|
|
93
|
-
],
|
|
94
|
-
qoder: [
|
|
95
|
-
"session-start.py",
|
|
96
|
-
"inject-shell-session-context.py",
|
|
97
|
-
"inject-workflow-state.py",
|
|
98
|
-
],
|
|
99
|
-
copilot: ["inject-workflow-state.py"],
|
|
100
|
-
codebuddy: [
|
|
101
|
-
"session-start.py",
|
|
102
|
-
"inject-shell-session-context.py",
|
|
103
|
-
"inject-workflow-state.py",
|
|
104
|
-
"inject-subagent-context.py",
|
|
105
|
-
],
|
|
106
|
-
droid: [
|
|
107
|
-
"session-start.py",
|
|
108
|
-
"inject-shell-session-context.py",
|
|
109
|
-
"inject-workflow-state.py",
|
|
110
|
-
"inject-subagent-context.py",
|
|
111
|
-
],
|
|
112
|
-
kiro: [
|
|
113
|
-
"session-start.py",
|
|
114
|
-
"inject-workflow-state.py",
|
|
115
|
-
"inject-subagent-context.py",
|
|
116
|
-
],
|
|
117
|
-
trae: [
|
|
118
|
-
"session-start.py",
|
|
119
|
-
"inject-shell-session-context.py",
|
|
120
|
-
"inject-workflow-state.py",
|
|
121
|
-
],
|
|
122
|
-
zcode: [
|
|
123
|
-
"session-start.py",
|
|
124
|
-
"inject-shell-session-context.py",
|
|
125
|
-
"inject-workflow-state.py",
|
|
126
|
-
"inject-subagent-context.py",
|
|
127
|
-
],
|
|
128
51
|
};
|
|
129
52
|
/**
|
|
130
53
|
* Get all shared hook scripts. Content is platform-independent and can be
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/templates/shared-hooks/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AAEtC,SAAS,YAAY,CAAC,YAAoB;IACxC,OAAO,YAAY,CAAC,IAAI,CAAC,SAAS,EAAE,YAAY,CAAC,EAAE,OAAO,CAAC,CAAC;AAC9D,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/templates/shared-hooks/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACpD,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,UAAU,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClD,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AAEtC,SAAS,YAAY,CAAC,YAAoB;IACxC,OAAO,YAAY,CAAC,IAAI,CAAC,SAAS,EAAE,YAAY,CAAC,EAAE,OAAO,CAAC,CAAC;AAC9D,CAAC;AAiBD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAGjC;IACF,MAAM,EAAE;QACN,kBAAkB;QAClB,0BAA0B;QAC1B,4BAA4B;QAC5B,wBAAwB;KACzB;IACD,KAAK,EAAE;QACL,0BAA0B;QAC1B,4BAA4B;QAC5B,wBAAwB;KACzB;CACF,CAAC;AAEF;;;GAGG;AACH,MAAM,UAAU,oBAAoB;IAClC,MAAM,OAAO,GAAiB,EAAE,CAAC;IACjC,MAAM,KAAK,GAAG,WAAW,CAAC,SAAS,CAAC;SACjC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;SAChC,IAAI,EAAE,CAAC;IAEV,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,OAAO,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,YAAY,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IAC5D,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,+BAA+B,CAC7C,QAA4B;IAE5B,MAAM,OAAO,GAAG,IAAI,GAAG,CAAS,wBAAwB,CAAC,QAAQ,CAAC,CAAC,CAAC;IACpE,OAAO,oBAAoB,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;AACnE,CAAC"}
|
|
@@ -364,7 +364,7 @@ def _shared_context_key(root: Path, payload: dict) -> str | None:
|
|
|
364
364
|
for session identity: payload keys in all casings (``session_id`` /
|
|
365
365
|
``sessionId`` / ``sessionID``, conversation and transcript variants),
|
|
366
366
|
nested payload shapes, the explicit ``TRELLIS_CONTEXT_ID`` override,
|
|
367
|
-
per-platform env fallbacks, and
|
|
367
|
+
per-platform env fallbacks, and shell tickets — plus the platform
|
|
368
368
|
fixes accumulated behind them. Payload identity is preferred over
|
|
369
369
|
environment context so two live sessions can never collapse onto one
|
|
370
370
|
exported env value (collision → missed injection is the unacceptable
|