@mindfoldhq/trellis 0.2.9 → 0.2.11
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 +76 -74
- package/dist/commands/update.js +3 -3
- package/dist/commands/update.js.map +1 -1
- package/dist/migrations/manifests/0.3.0.json +175 -0
- package/dist/templates/claude/commands/{check-cross-layer.md → trellis/check-cross-layer.md} +1 -1
- package/dist/templates/{cursor/commands → claude/commands/trellis}/create-command.md +9 -9
- package/dist/templates/claude/commands/{finish-work.md → trellis/finish-work.md} +5 -5
- package/dist/templates/{cursor/commands → claude/commands/trellis}/integrate-skill.md +4 -4
- package/dist/templates/claude/commands/{onboard.md → trellis/onboard.md} +32 -32
- package/dist/templates/claude/commands/{parallel.md → trellis/parallel.md} +6 -6
- package/dist/templates/claude/commands/{start.md → trellis/start.md} +6 -6
- package/dist/templates/claude/commands/{update-spec.md → trellis/update-spec.md} +5 -5
- package/dist/templates/claude/hooks/inject-subagent-context.py +14 -18
- package/dist/templates/claude/hooks/session-start.py +3 -1
- package/dist/templates/claude/index.d.ts +2 -0
- package/dist/templates/claude/index.d.ts.map +1 -1
- package/dist/templates/claude/index.js +4 -2
- package/dist/templates/claude/index.js.map +1 -1
- package/dist/templates/cursor/commands/{check-cross-layer.md → trellis-check-cross-layer.md} +1 -1
- package/dist/templates/{claude/commands/create-command.md → cursor/commands/trellis-create-command.md} +9 -9
- package/dist/templates/cursor/commands/{finish-work.md → trellis-finish-work.md} +5 -5
- package/dist/templates/{claude/commands/integrate-skill.md → cursor/commands/trellis-integrate-skill.md} +4 -4
- package/dist/templates/cursor/commands/{onboard.md → trellis-onboard.md} +32 -32
- package/dist/templates/cursor/commands/{start.md → trellis-start.md} +11 -11
- package/dist/templates/cursor/commands/{update-spec.md → trellis-update-spec.md} +5 -5
- package/dist/templates/cursor/index.d.ts +2 -0
- package/dist/templates/cursor/index.d.ts.map +1 -1
- package/dist/templates/cursor/index.js +2 -0
- package/dist/templates/cursor/index.js.map +1 -1
- package/dist/templates/markdown/agents.md +1 -1
- package/dist/templates/trellis/scripts/create-bootstrap.sh +2 -2
- package/dist/templates/trellis/scripts/multi-agent/create-pr.sh +4 -4
- package/dist/templates/trellis/scripts/task.sh +5 -5
- package/dist/templates/trellis/workflow.md +7 -7
- package/package.json +1 -1
- /package/dist/templates/claude/commands/{before-backend-dev.md → trellis/before-backend-dev.md} +0 -0
- /package/dist/templates/claude/commands/{before-frontend-dev.md → trellis/before-frontend-dev.md} +0 -0
- /package/dist/templates/claude/commands/{break-loop.md → trellis/break-loop.md} +0 -0
- /package/dist/templates/claude/commands/{check-backend.md → trellis/check-backend.md} +0 -0
- /package/dist/templates/claude/commands/{check-frontend.md → trellis/check-frontend.md} +0 -0
- /package/dist/templates/claude/commands/{record-session.md → trellis/record-session.md} +0 -0
- /package/dist/templates/cursor/commands/{before-backend-dev.md → trellis-before-backend-dev.md} +0 -0
- /package/dist/templates/cursor/commands/{before-frontend-dev.md → trellis-before-frontend-dev.md} +0 -0
- /package/dist/templates/cursor/commands/{break-loop.md → trellis-break-loop.md} +0 -0
- /package/dist/templates/cursor/commands/{check-backend.md → trellis-check-backend.md} +0 -0
- /package/dist/templates/cursor/commands/{check-frontend.md → trellis-check-frontend.md} +0 -0
- /package/dist/templates/cursor/commands/{record-session.md → trellis-record-session.md} +0 -0
|
@@ -31,14 +31,16 @@ function listFiles(dir) {
|
|
|
31
31
|
export const settingsTemplate = readTemplate("settings.json");
|
|
32
32
|
/**
|
|
33
33
|
* Get all command templates
|
|
34
|
+
* Commands are stored in commands/trellis/ subdirectory
|
|
35
|
+
* This creates commands like /trellis:start, /trellis:finish-work, etc.
|
|
34
36
|
*/
|
|
35
37
|
export function getAllCommands() {
|
|
36
38
|
const commands = [];
|
|
37
|
-
const files = listFiles("commands");
|
|
39
|
+
const files = listFiles("commands/trellis");
|
|
38
40
|
for (const file of files) {
|
|
39
41
|
if (file.endsWith(".md")) {
|
|
40
42
|
const name = file.replace(".md", "");
|
|
41
|
-
const content = readTemplate(`commands/${file}`);
|
|
43
|
+
const content = readTemplate(`commands/trellis/${file}`);
|
|
42
44
|
commands.push({ name, content });
|
|
43
45
|
}
|
|
44
46
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/templates/claude/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;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;AAED,SAAS,SAAS,CAAC,GAAW;IAC5B,IAAI,CAAC;QACH,OAAO,WAAW,CAAC,IAAI,CAAC,SAAS,EAAE,GAAG,CAAC,CAAC,CAAC;IAC3C,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,EAAE,CAAC;IACZ,CAAC;AACH,CAAC;AAED,WAAW;AACX,MAAM,CAAC,MAAM,gBAAgB,GAAG,YAAY,CAAC,eAAe,CAAC,CAAC;AA0B9D
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/templates/claude/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;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,MA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,IAAI,KAAK,EAAE,CAAC;QACzB,IAAI,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;YACzB,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;YACrC,MAAM,OAAO,GAAG,YAAY,CAAC,UAAU,IAAI,EAAE,CAAC,CAAC;YAC/C,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,CAAC;QACjC,CAAC;IACH,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,WAAW;IACzB,MAAM,KAAK,GAAmB,EAAE,CAAC;IACjC,MAAM,KAAK,GAAG,SAAS,CAAC,OAAO,CAAC,CAAC;IAEjC,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,MAAM,OAAO,GAAG,YAAY,CAAC,SAAS,IAAI,EAAE,CAAC,CAAC;QAC9C,KAAK,CAAC,IAAI,CAAC,EAAE,UAAU,EAAE,SAAS,IAAI,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC;IACvD,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,mBAAmB;IACjC,OAAO;QACL,UAAU,EAAE,eAAe;QAC3B,OAAO,EAAE,gBAAgB;KAC1B,CAAC;AACJ,CAAC"}
|
package/dist/templates/cursor/commands/{check-cross-layer.md → trellis-check-cross-layer.md}
RENAMED
|
@@ -12,7 +12,7 @@ Check if your changes considered all dimensions. Most bugs come from "didn't thi
|
|
|
12
12
|
|----------|---------|--------|
|
|
13
13
|
| [Pre-Implementation Checklist](.trellis/spec/guides/pre-implementation-checklist.md) | Questions before coding | **Before** writing code |
|
|
14
14
|
| [Code Reuse Thinking Guide](.trellis/spec/guides/code-reuse-thinking-guide.md) | Pattern recognition | During implementation |
|
|
15
|
-
| **`/check-cross-layer`** (this) | Verification check | **After** implementation |
|
|
15
|
+
| **`/trellis-check-cross-layer`** (this) | Verification check | **After** implementation |
|
|
16
16
|
|
|
17
17
|
---
|
|
18
18
|
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
# Create New Slash Command
|
|
2
2
|
|
|
3
|
-
Create a new slash command in both `.cursor/commands/` and `.claude/commands/` directories based on user requirements.
|
|
3
|
+
Create a new slash command in both `.cursor/commands/` (with `trellis-` prefix) and `.claude/commands/trellis/` directories based on user requirements.
|
|
4
4
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
7
7
|
```
|
|
8
|
-
/create-command <command-name> <description>
|
|
8
|
+
/trellis-create-command <command-name> <description>
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
**Example**:
|
|
12
12
|
```
|
|
13
|
-
/create-command review-pr Check PR code changes against project guidelines
|
|
13
|
+
/trellis-create-command review-pr Check PR code changes against project guidelines
|
|
14
14
|
```
|
|
15
15
|
|
|
16
16
|
## Execution Steps
|
|
@@ -61,8 +61,8 @@ Template
|
|
|
61
61
|
### 4. Create Files
|
|
62
62
|
|
|
63
63
|
Create in both directories:
|
|
64
|
-
- `.cursor/commands
|
|
65
|
-
- `.claude/commands/<command-name>.md`
|
|
64
|
+
- `.cursor/commands/trellis-<command-name>.md`
|
|
65
|
+
- `.claude/commands/trellis/<command-name>.md`
|
|
66
66
|
|
|
67
67
|
### 5. Confirm Creation
|
|
68
68
|
|
|
@@ -71,11 +71,11 @@ Output result:
|
|
|
71
71
|
[OK] Created Slash Command: /<command-name>
|
|
72
72
|
|
|
73
73
|
File paths:
|
|
74
|
-
- .cursor/commands
|
|
75
|
-
- .claude/commands/<command-name>.md
|
|
74
|
+
- .cursor/commands/trellis-<command-name>.md
|
|
75
|
+
- .claude/commands/trellis/<command-name>.md
|
|
76
76
|
|
|
77
77
|
Usage:
|
|
78
|
-
|
|
78
|
+
/trellis-<command-name>
|
|
79
79
|
|
|
80
80
|
Description:
|
|
81
81
|
<description>
|
|
@@ -112,7 +112,7 @@ Description:
|
|
|
112
112
|
|
|
113
113
|
### Input
|
|
114
114
|
```
|
|
115
|
-
/create-command review-pr Check PR code changes against project guidelines
|
|
115
|
+
/trellis-create-command review-pr Check PR code changes against project guidelines
|
|
116
116
|
```
|
|
117
117
|
|
|
118
118
|
### Generated Command Content
|
|
@@ -106,19 +106,19 @@ git diff --name-only
|
|
|
106
106
|
|
|
107
107
|
```
|
|
108
108
|
Development Flow:
|
|
109
|
-
Write code -> Test -> /finish-work -> git commit -> /record-session
|
|
109
|
+
Write code -> Test -> /trellis-finish-work -> git commit -> /trellis-record-session
|
|
110
110
|
| |
|
|
111
111
|
Ensure completeness Record progress
|
|
112
112
|
|
|
113
113
|
Debug Flow:
|
|
114
|
-
Hit bug -> Fix -> /break-loop -> Knowledge capture
|
|
114
|
+
Hit bug -> Fix -> /trellis-break-loop -> Knowledge capture
|
|
115
115
|
|
|
|
116
116
|
Deep analysis
|
|
117
117
|
```
|
|
118
118
|
|
|
119
|
-
- `/finish-work` - Check work completeness (this command)
|
|
120
|
-
- `/record-session` - Record session and commits
|
|
121
|
-
- `/break-loop` - Deep analysis after debugging
|
|
119
|
+
- `/trellis-finish-work` - Check work completeness (this command)
|
|
120
|
+
- `/trellis-record-session` - Record session and commits
|
|
121
|
+
- `/trellis-break-loop` - Deep analysis after debugging
|
|
122
122
|
|
|
123
123
|
---
|
|
124
124
|
|
|
@@ -5,13 +5,13 @@ Adapt and integrate a Claude global skill into your project's development guidel
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
7
7
|
```
|
|
8
|
-
/integrate-skill <skill-name>
|
|
8
|
+
/trellis-integrate-skill <skill-name>
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
**Examples**:
|
|
12
12
|
```
|
|
13
|
-
/integrate-skill frontend-design
|
|
14
|
-
/integrate-skill mcp-builder
|
|
13
|
+
/trellis-integrate-skill frontend-design
|
|
14
|
+
/trellis-integrate-skill mcp-builder
|
|
15
15
|
```
|
|
16
16
|
|
|
17
17
|
## Core Principle
|
|
@@ -169,7 +169,7 @@ yarn add <package>
|
|
|
169
169
|
If this skill is frequently used, create a shortcut command:
|
|
170
170
|
|
|
171
171
|
```bash
|
|
172
|
-
/create-command use-<skill-name> Use <skill-name> skill following project guidelines
|
|
172
|
+
/trellis-create-command use-<skill-name> Use <skill-name> skill following project guidelines
|
|
173
173
|
```
|
|
174
174
|
|
|
175
175
|
## Common Skill Integration Reference
|
|
@@ -41,7 +41,7 @@ Every AI session starts with a blank slate. Unlike human engineers who accumulat
|
|
|
41
41
|
|
|
42
42
|
**The Problem**: Without memory, AI asks the same questions repeatedly, makes the same mistakes, and can't build on previous work.
|
|
43
43
|
|
|
44
|
-
**The Solution**: The `.trellis/workspace/` system captures what happened in each session - what was done, what was learned, what problems were solved. The `/start` command reads this history at session start, giving AI "artificial memory."
|
|
44
|
+
**The Solution**: The `.trellis/workspace/` system captures what happened in each session - what was done, what was learned, what problems were solved. The `/trellis-start` command reads this history at session start, giving AI "artificial memory."
|
|
45
45
|
|
|
46
46
|
### Challenge 2: AI Has Generic Knowledge, Not Project-Specific Knowledge
|
|
47
47
|
|
|
@@ -57,7 +57,7 @@ Even after injecting guidelines, AI has limited context window. As conversation
|
|
|
57
57
|
|
|
58
58
|
**The Problem**: AI starts following guidelines, but as the session progresses and context fills up, it "forgets" the rules and reverts to generic patterns.
|
|
59
59
|
|
|
60
|
-
**The Solution**: The `/check-*` commands re-verify code against guidelines AFTER writing, catching drift that occurred during development. The `/finish-work` command does a final holistic review.
|
|
60
|
+
**The Solution**: The `/check-*` commands re-verify code against guidelines AFTER writing, catching drift that occurred during development. The `/trellis-finish-work` command does a final holistic review.
|
|
61
61
|
|
|
62
62
|
---
|
|
63
63
|
|
|
@@ -106,7 +106,7 @@ Even after injecting guidelines, AI has limited context window. As conversation
|
|
|
106
106
|
|
|
107
107
|
## COMMAND DEEP DIVE
|
|
108
108
|
|
|
109
|
-
### /start - Restore AI Memory
|
|
109
|
+
### /trellis-start - Restore AI Memory
|
|
110
110
|
|
|
111
111
|
**WHY IT EXISTS**:
|
|
112
112
|
When a human engineer joins a project, they spend days/weeks learning: What is this project? What's been built? What's in progress? What's the current state?
|
|
@@ -121,12 +121,12 @@ AI needs the same onboarding - but compressed into seconds at session start.
|
|
|
121
121
|
5. Understands current project state before making any changes
|
|
122
122
|
|
|
123
123
|
**WHY THIS MATTERS**:
|
|
124
|
-
- Without /start: AI is blind. It might work on wrong branch, conflict with others' work, or redo already-completed work.
|
|
125
|
-
- With /start: AI knows project context, can continue where previous session left off, avoids conflicts.
|
|
124
|
+
- Without /trellis-start: AI is blind. It might work on wrong branch, conflict with others' work, or redo already-completed work.
|
|
125
|
+
- With /trellis-start: AI knows project context, can continue where previous session left off, avoids conflicts.
|
|
126
126
|
|
|
127
127
|
---
|
|
128
128
|
|
|
129
|
-
### /before-frontend-dev and /before-backend-dev - Inject Specialized Knowledge
|
|
129
|
+
### /trellis-before-frontend-dev and /trellis-before-backend-dev - Inject Specialized Knowledge
|
|
130
130
|
|
|
131
131
|
**WHY IT EXISTS**:
|
|
132
132
|
AI models have "pre-trained knowledge" - general patterns from millions of codebases. But YOUR project has specific conventions that differ from generic patterns.
|
|
@@ -145,7 +145,7 @@ AI models have "pre-trained knowledge" - general patterns from millions of codeb
|
|
|
145
145
|
|
|
146
146
|
---
|
|
147
147
|
|
|
148
|
-
### /check-frontend and /check-backend - Combat Context Drift
|
|
148
|
+
### /trellis-check-frontend and /trellis-check-backend - Combat Context Drift
|
|
149
149
|
|
|
150
150
|
**WHY IT EXISTS**:
|
|
151
151
|
AI context window has limited capacity. As conversation progresses, guidelines injected at session start become less influential. This causes "context drift."
|
|
@@ -162,7 +162,7 @@ AI context window has limited capacity. As conversation progresses, guidelines i
|
|
|
162
162
|
|
|
163
163
|
---
|
|
164
164
|
|
|
165
|
-
### /check-cross-layer - Multi-Dimension Verification
|
|
165
|
+
### /trellis-check-cross-layer - Multi-Dimension Verification
|
|
166
166
|
|
|
167
167
|
**WHY IT EXISTS**:
|
|
168
168
|
Most bugs don't come from lack of technical skill - they come from "didn't think of it":
|
|
@@ -180,7 +180,7 @@ Most bugs don't come from lack of technical skill - they come from "didn't think
|
|
|
180
180
|
|
|
181
181
|
---
|
|
182
182
|
|
|
183
|
-
### /finish-work - Holistic Pre-Commit Review
|
|
183
|
+
### /trellis-finish-work - Holistic Pre-Commit Review
|
|
184
184
|
|
|
185
185
|
**WHY IT EXISTS**:
|
|
186
186
|
The `/check-*` commands focus on code quality within a single layer. But real changes often have cross-cutting concerns.
|
|
@@ -193,10 +193,10 @@ The `/check-*` commands focus on code quality within a single layer. But real ch
|
|
|
193
193
|
|
|
194
194
|
---
|
|
195
195
|
|
|
196
|
-
### /record-session - Persist Memory for Future
|
|
196
|
+
### /trellis-record-session - Persist Memory for Future
|
|
197
197
|
|
|
198
198
|
**WHY IT EXISTS**:
|
|
199
|
-
All the context AI built during this session will be lost when session ends. The next session's `/start` needs this information.
|
|
199
|
+
All the context AI built during this session will be lost when session ends. The next session's `/trellis-start` needs this information.
|
|
200
200
|
|
|
201
201
|
**WHAT IT ACTUALLY DOES**:
|
|
202
202
|
1. Records session summary to `workspace/{developer}/journal-N.md`
|
|
@@ -209,47 +209,47 @@ All the context AI built during this session will be lost when session ends. The
|
|
|
209
209
|
|
|
210
210
|
### Example 1: Bug Fix Session
|
|
211
211
|
|
|
212
|
-
**[1/8] /start** - AI needs project context before touching code
|
|
212
|
+
**[1/8] /trellis-start** - AI needs project context before touching code
|
|
213
213
|
**[2/8] ./.trellis/scripts/task.sh create "Fix bug" --slug fix-bug** - Track work for future reference
|
|
214
|
-
**[3/8] /before-frontend-dev** - Inject project-specific frontend knowledge
|
|
214
|
+
**[3/8] /trellis-before-frontend-dev** - Inject project-specific frontend knowledge
|
|
215
215
|
**[4/8] Investigate and fix the bug** - Actual development work
|
|
216
|
-
**[5/8] /check-frontend** - Re-verify code against guidelines
|
|
217
|
-
**[6/8] /finish-work** - Holistic cross-layer review
|
|
216
|
+
**[5/8] /trellis-check-frontend** - Re-verify code against guidelines
|
|
217
|
+
**[6/8] /trellis-finish-work** - Holistic cross-layer review
|
|
218
218
|
**[7/8] Human tests and commits** - Human validates before code enters repo
|
|
219
|
-
**[8/8] /record-session** - Persist memory for future sessions
|
|
219
|
+
**[8/8] /trellis-record-session** - Persist memory for future sessions
|
|
220
220
|
|
|
221
221
|
### Example 2: Planning Session (No Code)
|
|
222
222
|
|
|
223
|
-
**[1/4] /start** - Context needed even for non-coding work
|
|
223
|
+
**[1/4] /trellis-start** - Context needed even for non-coding work
|
|
224
224
|
**[2/4] ./.trellis/scripts/task.sh create "Planning task" --slug planning-task** - Planning is valuable work
|
|
225
225
|
**[3/4] Review docs, create subtask list** - Actual planning work
|
|
226
|
-
**[4/4] /record-session (with --summary)** - Planning decisions must be recorded
|
|
226
|
+
**[4/4] /trellis-record-session (with --summary)** - Planning decisions must be recorded
|
|
227
227
|
|
|
228
228
|
### Example 3: Code Review Fixes
|
|
229
229
|
|
|
230
|
-
**[1/6] /start** - Resume context from previous session
|
|
231
|
-
**[2/6] /before-backend-dev** - Re-inject guidelines before fixes
|
|
230
|
+
**[1/6] /trellis-start** - Resume context from previous session
|
|
231
|
+
**[2/6] /trellis-before-backend-dev** - Re-inject guidelines before fixes
|
|
232
232
|
**[3/6] Fix each CR issue** - Address feedback with guidelines in context
|
|
233
|
-
**[4/6] /check-backend** - Verify fixes didn't introduce new issues
|
|
234
|
-
**[5/6] /finish-work** - Document lessons from CR
|
|
235
|
-
**[6/6] Human commits, then /record-session** - Preserve CR lessons
|
|
233
|
+
**[4/6] /trellis-check-backend** - Verify fixes didn't introduce new issues
|
|
234
|
+
**[5/6] /trellis-finish-work** - Document lessons from CR
|
|
235
|
+
**[6/6] Human commits, then /trellis-record-session** - Preserve CR lessons
|
|
236
236
|
|
|
237
237
|
### Example 4: Large Refactoring
|
|
238
238
|
|
|
239
|
-
**[1/5] /start** - Clear baseline before major changes
|
|
239
|
+
**[1/5] /trellis-start** - Clear baseline before major changes
|
|
240
240
|
**[2/5] Plan phases** - Break into verifiable chunks
|
|
241
241
|
**[3/5] Execute phase by phase with /check-* after each** - Incremental verification
|
|
242
|
-
**[4/5] /finish-work** - Check if new patterns should be documented
|
|
242
|
+
**[4/5] /trellis-finish-work** - Check if new patterns should be documented
|
|
243
243
|
**[5/5] Record with multiple commit hashes** - Link all commits to one feature
|
|
244
244
|
|
|
245
245
|
### Example 5: Debug Session
|
|
246
246
|
|
|
247
|
-
**[1/6] /start** - See if this bug was investigated before
|
|
248
|
-
**[2/6] /before-backend-dev** - Guidelines might document known gotchas
|
|
247
|
+
**[1/6] /trellis-start** - See if this bug was investigated before
|
|
248
|
+
**[2/6] /trellis-before-backend-dev** - Guidelines might document known gotchas
|
|
249
249
|
**[3/6] Investigation** - Actual debugging work
|
|
250
|
-
**[4/6] /check-backend** - Verify debug changes don't break other things
|
|
251
|
-
**[5/6] /finish-work** - Debug findings might need documentation
|
|
252
|
-
**[6/6] Human commits, then /record-session** - Debug knowledge is valuable
|
|
250
|
+
**[4/6] /trellis-check-backend** - Verify debug changes don't break other things
|
|
251
|
+
**[5/6] /trellis-finish-work** - Debug findings might need documentation
|
|
252
|
+
**[6/6] Human commits, then /trellis-record-session** - Debug knowledge is valuable
|
|
253
253
|
|
|
254
254
|
---
|
|
255
255
|
|
|
@@ -258,7 +258,7 @@ All the context AI built during this session will be lost when session ends. The
|
|
|
258
258
|
1. **AI NEVER commits** - Human tests and approves. AI prepares, human validates.
|
|
259
259
|
2. **Guidelines before code** - /before-*-dev commands inject project knowledge.
|
|
260
260
|
3. **Check after code** - /check-* commands catch context drift.
|
|
261
|
-
4. **Record everything** - /record-session persists memory.
|
|
261
|
+
4. **Record everything** - /trellis-record-session persists memory.
|
|
262
262
|
|
|
263
263
|
---
|
|
264
264
|
|
|
@@ -351,7 +351,7 @@ After covering all three parts, summarize:
|
|
|
351
351
|
- Part 3: Guidelines status (empty templates need filling / already customized)
|
|
352
352
|
|
|
353
353
|
**Next steps** (tell user):
|
|
354
|
-
1. Run `/record-session` to record this onboard session
|
|
354
|
+
1. Run `/trellis-record-session` to record this onboard session
|
|
355
355
|
2. [If guidelines empty] Start filling in `.trellis/spec/` guidelines
|
|
356
356
|
3. [If guidelines ready] Start your first development task
|
|
357
357
|
|
|
@@ -92,7 +92,7 @@ Ready for your task. What would you like to work on?
|
|
|
92
92
|
|
|
93
93
|
1. Read relevant guidelines based on task type `[AI]`
|
|
94
94
|
2. Implement the task directly `[AI]`
|
|
95
|
-
3. Remind user to run `/finish-work` before committing `[USER]`
|
|
95
|
+
3. Remind user to run `/trellis-finish-work` before committing `[USER]`
|
|
96
96
|
|
|
97
97
|
### For Complex Tasks (Multi-Step Tasks)
|
|
98
98
|
|
|
@@ -113,7 +113,7 @@ Ready for your task. What would you like to work on?
|
|
|
113
113
|
1. Verify typecheck and lint pass `[AI]`
|
|
114
114
|
2. Remind user to test
|
|
115
115
|
3. Remind user to commit
|
|
116
|
-
4. Remind user to run `/record-session` `[USER]`
|
|
116
|
+
4. Remind user to run `/trellis-record-session` `[USER]`
|
|
117
117
|
5. Archive task `[AI]`:
|
|
118
118
|
```bash
|
|
119
119
|
./.trellis/scripts/task.sh archive <task-name>
|
|
@@ -127,14 +127,14 @@ The following slash commands are for users (not AI):
|
|
|
127
127
|
|
|
128
128
|
| Command | Description |
|
|
129
129
|
|---------|-------------|
|
|
130
|
-
| `/start` | Start development session (this command) |
|
|
131
|
-
| `/before-frontend-dev` | Read frontend guidelines |
|
|
132
|
-
| `/before-backend-dev` | Read backend guidelines |
|
|
133
|
-
| `/check-frontend` | Check frontend code |
|
|
134
|
-
| `/check-backend` | Check backend code |
|
|
135
|
-
| `/check-cross-layer` | Cross-layer verification |
|
|
136
|
-
| `/finish-work` | Pre-commit checklist |
|
|
137
|
-
| `/record-session` | Record session progress |
|
|
130
|
+
| `/trellis-start` | Start development session (this command) |
|
|
131
|
+
| `/trellis-before-frontend-dev` | Read frontend guidelines |
|
|
132
|
+
| `/trellis-before-backend-dev` | Read backend guidelines |
|
|
133
|
+
| `/trellis-check-frontend` | Check frontend code |
|
|
134
|
+
| `/trellis-check-backend` | Check backend code |
|
|
135
|
+
| `/trellis-check-cross-layer` | Cross-layer verification |
|
|
136
|
+
| `/trellis-finish-work` | Pre-commit checklist |
|
|
137
|
+
| `/trellis-record-session` | Record session progress |
|
|
138
138
|
|
|
139
139
|
---
|
|
140
140
|
|
|
@@ -153,4 +153,4 @@ The following slash commands are for users (not AI):
|
|
|
153
153
|
|
|
154
154
|
**IMPORTANT**: When a task or session is completed, remind the user:
|
|
155
155
|
|
|
156
|
-
> Before ending this session, please run `/record-session` to record what we accomplished.
|
|
156
|
+
> Before ending this session, please run `/trellis-record-session` to record what we accomplished.
|
|
@@ -191,15 +191,15 @@ Before finishing your spec update:
|
|
|
191
191
|
|
|
192
192
|
```
|
|
193
193
|
Development Flow:
|
|
194
|
-
Learn something → /update-spec → Knowledge captured
|
|
194
|
+
Learn something → /trellis-update-spec → Knowledge captured
|
|
195
195
|
↑ ↓
|
|
196
|
-
/break-loop ←──────────────────── Future sessions benefit
|
|
196
|
+
/trellis-break-loop ←──────────────────── Future sessions benefit
|
|
197
197
|
(deep bug analysis)
|
|
198
198
|
```
|
|
199
199
|
|
|
200
|
-
- `/break-loop` - Analyzes bugs deeply, often reveals spec updates needed
|
|
201
|
-
- `/update-spec` - Actually makes the updates (this command)
|
|
202
|
-
- `/finish-work` - Reminds you to check if specs need updates
|
|
200
|
+
- `/trellis-break-loop` - Analyzes bugs deeply, often reveals spec updates needed
|
|
201
|
+
- `/trellis-update-spec` - Actually makes the updates (this command)
|
|
202
|
+
- `/trellis-finish-work` - Reminds you to check if specs need updates
|
|
203
203
|
|
|
204
204
|
---
|
|
205
205
|
|
|
@@ -17,6 +17,8 @@ export interface CommandTemplate {
|
|
|
17
17
|
}
|
|
18
18
|
/**
|
|
19
19
|
* Get all command templates
|
|
20
|
+
* Commands use trellis- prefix in filename (e.g., trellis-start.md → /trellis-start)
|
|
21
|
+
* Cursor doesn't support subdirectory namespacing like Claude Code does
|
|
20
22
|
*/
|
|
21
23
|
export declare function getAllCommands(): CommandTemplate[];
|
|
22
24
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/cursor/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAqBH;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/cursor/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAqBH;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;GAIG;AACH,wBAAgB,cAAc,IAAI,eAAe,EAAE,CAalD"}
|
|
@@ -26,6 +26,8 @@ function listFiles(dir) {
|
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
28
28
|
* Get all command templates
|
|
29
|
+
* Commands use trellis- prefix in filename (e.g., trellis-start.md → /trellis-start)
|
|
30
|
+
* Cursor doesn't support subdirectory namespacing like Claude Code does
|
|
29
31
|
*/
|
|
30
32
|
export function getAllCommands() {
|
|
31
33
|
const commands = [];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/templates/cursor/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;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,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AS,CAAC,UAAU,CAAC,CAAC;IAEpC,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,IAAI,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;YACzB,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;YACrC,MAAM,OAAO,GAAG,YAAY,CAAC,YAAY,IAAI,EAAE,CAAC,CAAC;YACjD,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,CAAC;QACnC,CAAC;IACH,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
These instructions are for AI assistants working in this project.
|
|
5
5
|
|
|
6
|
-
Use the `/start` command when starting a new session to:
|
|
6
|
+
Use the `/trellis:start` command when starting a new session to:
|
|
7
7
|
- Initialize your developer identity
|
|
8
8
|
- Understand current project context
|
|
9
9
|
- Read relevant guidelines
|
|
@@ -160,8 +160,8 @@ When done:
|
|
|
160
160
|
After completing this task:
|
|
161
161
|
|
|
162
162
|
1. AI will write code that matches your project style
|
|
163
|
-
2. Relevant `/before-*-dev` commands will inject real context
|
|
164
|
-
3. `/check-*` commands will validate against your actual standards
|
|
163
|
+
2. Relevant `/trellis:before-*-dev` commands will inject real context
|
|
164
|
+
3. `/trellis:check-*` commands will validate against your actual standards
|
|
165
165
|
4. Future developers (human or AI) will onboard faster
|
|
166
166
|
EOF
|
|
167
167
|
}
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
# 1. Stages and commits all changes (excluding workspace/)
|
|
10
10
|
# 2. Pushes to origin
|
|
11
11
|
# 3. Creates a Draft PR using `gh pr create`
|
|
12
|
-
# 4. Updates task.json with status="
|
|
12
|
+
# 4. Updates task.json with status="completed", pr_url, and current_phase
|
|
13
13
|
#
|
|
14
14
|
# Note: This is the only action that performs git commit, as it's the final
|
|
15
15
|
# step after all implementation and checks are complete.
|
|
@@ -215,7 +215,7 @@ fi
|
|
|
215
215
|
echo -e "${YELLOW}Updating task status...${NC}"
|
|
216
216
|
if [[ "$DRY_RUN" == "true" ]]; then
|
|
217
217
|
echo -e "[DRY-RUN] Would update task.json:"
|
|
218
|
-
echo -e " status:
|
|
218
|
+
echo -e " status: completed"
|
|
219
219
|
echo -e " pr_url: ${PR_URL}"
|
|
220
220
|
echo -e " current_phase: (set to create-pr phase)"
|
|
221
221
|
else
|
|
@@ -226,9 +226,9 @@ else
|
|
|
226
226
|
fi
|
|
227
227
|
|
|
228
228
|
jq --arg url "$PR_URL" --argjson phase "$CREATE_PR_PHASE" \
|
|
229
|
-
'.status = "
|
|
229
|
+
'.status = "completed" | .pr_url = $url | .current_phase = $phase' "$TASK_JSON" > "${TASK_JSON}.tmp"
|
|
230
230
|
mv "${TASK_JSON}.tmp" "$TASK_JSON"
|
|
231
|
-
echo -e "${GREEN}Task status updated to '
|
|
231
|
+
echo -e "${GREEN}Task status updated to 'completed', phase ${CREATE_PR_PHASE}${NC}"
|
|
232
232
|
fi
|
|
233
233
|
|
|
234
234
|
# In dry-run, reset the staging area
|
|
@@ -87,15 +87,15 @@ get_check_context() {
|
|
|
87
87
|
local dev_type="$1"
|
|
88
88
|
|
|
89
89
|
cat << EOF
|
|
90
|
-
{"file": ".claude/commands/finish-work.md", "reason": "Finish work checklist"}
|
|
90
|
+
{"file": ".claude/commands/trellis/finish-work.md", "reason": "Finish work checklist"}
|
|
91
91
|
{"file": "$DIR_WORKFLOW/$DIR_SPEC/shared/index.md", "reason": "Shared coding standards"}
|
|
92
92
|
EOF
|
|
93
93
|
|
|
94
94
|
if [[ "$dev_type" == "backend" ]] || [[ "$dev_type" == "fullstack" ]]; then
|
|
95
|
-
echo '{"file": ".claude/commands/check-backend.md", "reason": "Backend check spec"}'
|
|
95
|
+
echo '{"file": ".claude/commands/trellis/check-backend.md", "reason": "Backend check spec"}'
|
|
96
96
|
fi
|
|
97
97
|
if [[ "$dev_type" == "frontend" ]] || [[ "$dev_type" == "fullstack" ]]; then
|
|
98
|
-
echo '{"file": ".claude/commands/check-frontend.md", "reason": "Frontend check spec"}'
|
|
98
|
+
echo '{"file": ".claude/commands/trellis/check-frontend.md", "reason": "Frontend check spec"}'
|
|
99
99
|
fi
|
|
100
100
|
}
|
|
101
101
|
|
|
@@ -105,10 +105,10 @@ get_debug_context() {
|
|
|
105
105
|
echo "{\"file\": \"$DIR_WORKFLOW/$DIR_SPEC/shared/index.md\", \"reason\": \"Shared coding standards\"}"
|
|
106
106
|
|
|
107
107
|
if [[ "$dev_type" == "backend" ]] || [[ "$dev_type" == "fullstack" ]]; then
|
|
108
|
-
echo '{"file": ".claude/commands/check-backend.md", "reason": "Backend check spec"}'
|
|
108
|
+
echo '{"file": ".claude/commands/trellis/check-backend.md", "reason": "Backend check spec"}'
|
|
109
109
|
fi
|
|
110
110
|
if [[ "$dev_type" == "frontend" ]] || [[ "$dev_type" == "fullstack" ]]; then
|
|
111
|
-
echo '{"file": ".claude/commands/check-frontend.md", "reason": "Frontend check spec"}'
|
|
111
|
+
echo '{"file": ".claude/commands/trellis/check-frontend.md", "reason": "Frontend check spec"}'
|
|
112
112
|
fi
|
|
113
113
|
}
|
|
114
114
|
|
|
@@ -250,7 +250,7 @@ This automatically:
|
|
|
250
250
|
|
|
251
251
|
### Pre-end Checklist
|
|
252
252
|
|
|
253
|
-
Use `/finish-work` command to run through:
|
|
253
|
+
Use `/trellis:finish-work` command to run through:
|
|
254
254
|
1. [OK] All code committed, commit message follows convention
|
|
255
255
|
2. [OK] Session recorded via `add-session.sh`
|
|
256
256
|
3. [OK] No lint/test errors
|
|
@@ -336,13 +336,13 @@ tasks/
|
|
|
336
336
|
|
|
337
337
|
2. **During development**:
|
|
338
338
|
- [!] **Follow** `.trellis/spec/` guidelines
|
|
339
|
-
- For cross-layer features, use `/check-cross-layer`
|
|
339
|
+
- For cross-layer features, use `/trellis:check-cross-layer`
|
|
340
340
|
- Develop only one task at a time
|
|
341
341
|
- Run lint and tests frequently
|
|
342
342
|
|
|
343
343
|
3. **After development complete**:
|
|
344
|
-
- Use `/finish-work` for completion checklist
|
|
345
|
-
- After fix bug, use `/break-loop` for deep analysis
|
|
344
|
+
- Use `/trellis:finish-work` for completion checklist
|
|
345
|
+
- After fix bug, use `/trellis:break-loop` for deep analysis
|
|
346
346
|
- Human commits after testing passes
|
|
347
347
|
- Use `add-session.sh` to record progress
|
|
348
348
|
|
|
@@ -388,9 +388,9 @@ git commit -m "type(scope): description"
|
|
|
388
388
|
./.trellis/scripts/task.sh create "<title>" # Create task
|
|
389
389
|
|
|
390
390
|
# Slash commands
|
|
391
|
-
/finish-work # Pre-commit checklist
|
|
392
|
-
/break-loop # Post-debug analysis
|
|
393
|
-
/check-cross-layer # Cross-layer verification
|
|
391
|
+
/trellis:finish-work # Pre-commit checklist
|
|
392
|
+
/trellis:break-loop # Post-debug analysis
|
|
393
|
+
/trellis:check-cross-layer # Cross-layer verification
|
|
394
394
|
```
|
|
395
395
|
|
|
396
396
|
---
|
package/package.json
CHANGED
/package/dist/templates/claude/commands/{before-backend-dev.md → trellis/before-backend-dev.md}
RENAMED
|
File without changes
|
/package/dist/templates/claude/commands/{before-frontend-dev.md → trellis/before-frontend-dev.md}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/dist/templates/cursor/commands/{before-backend-dev.md → trellis-before-backend-dev.md}
RENAMED
|
File without changes
|
/package/dist/templates/cursor/commands/{before-frontend-dev.md → trellis-before-frontend-dev.md}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|