opencodekit 0.16.15 → 0.16.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/README.md +77 -242
  2. package/dist/index.js +19 -6
  3. package/dist/template/.opencode/AGENTS.md +72 -236
  4. package/dist/template/.opencode/README.md +49 -482
  5. package/dist/template/.opencode/agent/build.md +71 -345
  6. package/dist/template/.opencode/agent/explore.md +47 -139
  7. package/dist/template/.opencode/agent/general.md +61 -172
  8. package/dist/template/.opencode/agent/looker.md +65 -161
  9. package/dist/template/.opencode/agent/painter.md +46 -200
  10. package/dist/template/.opencode/agent/plan.md +37 -220
  11. package/dist/template/.opencode/agent/review.md +72 -153
  12. package/dist/template/.opencode/agent/scout.md +44 -486
  13. package/dist/template/.opencode/agent/vision.md +63 -178
  14. package/dist/template/.opencode/command/create.md +75 -307
  15. package/dist/template/.opencode/command/design.md +53 -589
  16. package/dist/template/.opencode/command/handoff.md +76 -180
  17. package/dist/template/.opencode/command/init.md +45 -211
  18. package/dist/template/.opencode/command/plan.md +62 -514
  19. package/dist/template/.opencode/command/pr.md +56 -226
  20. package/dist/template/.opencode/command/research.md +55 -266
  21. package/dist/template/.opencode/command/resume.md +33 -138
  22. package/dist/template/.opencode/command/review-codebase.md +54 -202
  23. package/dist/template/.opencode/command/ship.md +78 -127
  24. package/dist/template/.opencode/command/start.md +47 -577
  25. package/dist/template/.opencode/command/status.md +60 -353
  26. package/dist/template/.opencode/command/ui-review.md +52 -298
  27. package/dist/template/.opencode/command/verify.md +36 -250
  28. package/dist/template/.opencode/memory.db-shm +0 -0
  29. package/dist/template/.opencode/memory.db-wal +0 -0
  30. package/dist/template/.opencode/opencode.json +133 -35
  31. package/dist/template/.opencode/plugin/README.md +40 -166
  32. package/dist/template/.opencode/plugin/compaction.ts +162 -131
  33. package/dist/template/.opencode/plugin/lib/memory-db.ts +112 -0
  34. package/dist/template/.opencode/plugin/swarm-enforcer.ts +182 -27
  35. package/dist/template/.opencode/skill/augment-context-engine/SKILL.md +112 -0
  36. package/dist/template/.opencode/skill/augment-context-engine/mcp.json +6 -0
  37. package/dist/template/.opencode/skill/core-data-expert/SKILL.md +82 -0
  38. package/dist/template/.opencode/skill/core-data-expert/references/batch-operations.md +543 -0
  39. package/dist/template/.opencode/skill/core-data-expert/references/cloudkit-integration.md +259 -0
  40. package/dist/template/.opencode/skill/core-data-expert/references/concurrency.md +522 -0
  41. package/dist/template/.opencode/skill/core-data-expert/references/fetch-requests.md +643 -0
  42. package/dist/template/.opencode/skill/core-data-expert/references/glossary.md +233 -0
  43. package/dist/template/.opencode/skill/core-data-expert/references/migration.md +393 -0
  44. package/dist/template/.opencode/skill/core-data-expert/references/model-configuration.md +597 -0
  45. package/dist/template/.opencode/skill/core-data-expert/references/performance.md +300 -0
  46. package/dist/template/.opencode/skill/core-data-expert/references/persistent-history.md +553 -0
  47. package/dist/template/.opencode/skill/core-data-expert/references/project-audit.md +60 -0
  48. package/dist/template/.opencode/skill/core-data-expert/references/saving.md +574 -0
  49. package/dist/template/.opencode/skill/core-data-expert/references/stack-setup.md +625 -0
  50. package/dist/template/.opencode/skill/core-data-expert/references/testing.md +300 -0
  51. package/dist/template/.opencode/skill/core-data-expert/references/threading.md +589 -0
  52. package/dist/template/.opencode/skill/swift-concurrency/SKILL.md +246 -0
  53. package/dist/template/.opencode/skill/swift-concurrency/references/actors.md +640 -0
  54. package/dist/template/.opencode/skill/swift-concurrency/references/async-algorithms.md +822 -0
  55. package/dist/template/.opencode/skill/swift-concurrency/references/async-await-basics.md +249 -0
  56. package/dist/template/.opencode/skill/swift-concurrency/references/async-sequences.md +670 -0
  57. package/dist/template/.opencode/skill/swift-concurrency/references/core-data.md +533 -0
  58. package/dist/template/.opencode/skill/swift-concurrency/references/glossary.md +128 -0
  59. package/dist/template/.opencode/skill/swift-concurrency/references/linting.md +142 -0
  60. package/dist/template/.opencode/skill/swift-concurrency/references/memory-management.md +542 -0
  61. package/dist/template/.opencode/skill/swift-concurrency/references/migration.md +1076 -0
  62. package/dist/template/.opencode/skill/swift-concurrency/references/performance.md +574 -0
  63. package/dist/template/.opencode/skill/swift-concurrency/references/sendable.md +578 -0
  64. package/dist/template/.opencode/skill/swift-concurrency/references/tasks.md +604 -0
  65. package/dist/template/.opencode/skill/swift-concurrency/references/testing.md +565 -0
  66. package/dist/template/.opencode/skill/swift-concurrency/references/threading.md +452 -0
  67. package/dist/template/.opencode/skill/swiftui-expert-skill/SKILL.md +290 -0
  68. package/dist/template/.opencode/skill/swiftui-expert-skill/references/animation-advanced.md +351 -0
  69. package/dist/template/.opencode/skill/swiftui-expert-skill/references/animation-basics.md +284 -0
  70. package/dist/template/.opencode/skill/swiftui-expert-skill/references/animation-transitions.md +326 -0
  71. package/dist/template/.opencode/skill/swiftui-expert-skill/references/image-optimization.md +286 -0
  72. package/dist/template/.opencode/skill/swiftui-expert-skill/references/layout-best-practices.md +312 -0
  73. package/dist/template/.opencode/skill/swiftui-expert-skill/references/liquid-glass.md +377 -0
  74. package/dist/template/.opencode/skill/swiftui-expert-skill/references/list-patterns.md +153 -0
  75. package/dist/template/.opencode/skill/swiftui-expert-skill/references/modern-apis.md +400 -0
  76. package/dist/template/.opencode/skill/swiftui-expert-skill/references/performance-patterns.md +377 -0
  77. package/dist/template/.opencode/skill/swiftui-expert-skill/references/scroll-patterns.md +305 -0
  78. package/dist/template/.opencode/skill/swiftui-expert-skill/references/sheet-navigation-patterns.md +292 -0
  79. package/dist/template/.opencode/skill/swiftui-expert-skill/references/state-management.md +447 -0
  80. package/dist/template/.opencode/skill/swiftui-expert-skill/references/text-formatting.md +285 -0
  81. package/dist/template/.opencode/skill/swiftui-expert-skill/references/view-structure.md +276 -0
  82. package/dist/template/.opencode/tool/action-queue.ts +308 -0
  83. package/dist/template/.opencode/tool/swarm.ts +65 -40
  84. package/package.json +16 -3
  85. package/dist/template/.opencode/.agents/skills/context7/SKILL.md +0 -88
@@ -1,303 +1,133 @@
1
1
  ---
2
2
  description: Create and submit pull request with bead traceability
3
- argument-hint: "<bead-id> [--draft] [--wait]"
3
+ argument-hint: "[bead-id] [--draft]"
4
4
  agent: build
5
5
  ---
6
6
 
7
7
  # Pull Request
8
8
 
9
- **Load skills:**
9
+ ## Load Skills
10
10
 
11
11
  ```typescript
12
- skill({ name: "beads" }); // Session protocol
12
+ skill({ name: "beads" });
13
13
  skill({ name: "verification-before-completion" });
14
- skill({ name: "memory-system" });
15
14
  ```
16
15
 
17
- ## Check Memory for Related Context
16
+ ## Parse Arguments
18
17
 
19
- Search for related decisions and patterns:
20
-
21
- ```typescript
22
- // Find related decisions and patterns for this work
23
- memory_search({ query: "$ARGUMENTS [feature keywords]", limit: 3 });
24
-
25
- // Find any gotchas related to this area
26
- memory_search({ query: "[affected files/modules] gotchas", limit: 2 });
27
- ```
28
-
29
- Include relevant context from memory in PR description.
30
-
31
- ## Options
32
-
33
- - `--draft`: Create as draft PR (for WIP or early feedback)
34
- - `--wait`: Wait for CI checks to pass after creation
18
+ | Argument | Default | Description |
19
+ | ----------- | -------- | ------------------ |
20
+ | `<bead-id>` | optional | Link PR to bead |
21
+ | `--draft` | false | Create as draft PR |
35
22
 
36
23
  ## Phase 1: Pre-PR Verification
37
24
 
38
- Before creating PR, run verification gates:
39
-
40
- ```
41
- !`git status --porcelain` # Check for uncommitted changes
42
- ```
43
-
44
- If uncommitted changes exist, ask: "Commit these changes first?"
45
-
46
- Run project gates:
47
-
48
- ```
49
- !`npm run build 2>&1 | tail -5`
50
- !`npm test 2>&1 | tail -10`
51
- !`npm run lint 2>&1 | tail -5`
52
- ```
53
-
54
- ```
55
- Pre-PR Gates:
56
- ━━━━━━━━━━━━━
57
-
58
- Build: [✓/✗]
59
- Tests: [✓/✗]
60
- Lint: [✓/✗]
61
- ```
62
-
63
- **If any gate fails: STOP.**
64
-
65
- ```
66
- Cannot create PR: [gate] failed.
67
-
68
- Fix errors first, then run /pr again.
69
- ```
70
-
71
- ## Phase 2: Check for Conflicts
72
-
73
- ```
74
- !`git fetch origin main`
75
- !`git merge-base --is-ancestor origin/main HEAD || git diff origin/main...HEAD --name-only`
25
+ ```bash
26
+ git status --porcelain
76
27
  ```
77
28
 
78
- Check for merge conflicts:
29
+ If uncommitted changes exist, ask whether to commit first.
79
30
 
80
- ```
81
- !`git merge --no-commit --no-ff origin/main 2>&1 || true`
82
- !`git merge --abort 2>/dev/null || true`
83
- ```
31
+ Run verification gates. Detect project type and use the appropriate commands:
84
32
 
85
- If conflicts detected:
33
+ | Project Type | Detect Via | Build | Test | Lint | Typecheck |
34
+ | --------------- | ----------------------------- | ---------------- | --------------- | ----------------------------- | ------------------------------------- |
35
+ | Node/TypeScript | `package.json` | `npm run build` | `npm test` | `npm run lint` | `npm run typecheck` or `tsc --noEmit` |
36
+ | Rust | `Cargo.toml` | `cargo build` | `cargo test` | `cargo clippy -- -D warnings` | (included in build) |
37
+ | Python | `pyproject.toml` / `setup.py` | — | `pytest` | `ruff check .` | `mypy .` |
38
+ | Go | `go.mod` | `go build ./...` | `go test ./...` | `golangci-lint run` | (included in build) |
86
39
 
87
- ```
88
- ⚠️ Merge conflicts detected with main:
89
- - [file1]
90
- - [file2]
91
-
92
- Resolve conflicts before creating PR:
93
- git fetch origin main
94
- git rebase origin/main
95
- # Fix conflicts, then /pr again
96
- ```
40
+ Check `package.json` scripts, `Makefile`, or `justfile` for project-specific commands first — prefer those over generic defaults.
97
41
 
98
- ## Phase 3: Gather Context
42
+ If any gate fails, stop. Fix errors first, then run `/pr` again.
99
43
 
100
- **Current state:**
44
+ ## Phase 2: Gather Context
101
45
 
102
- ```
103
- !`git branch --show-current`
104
- !`git diff main...HEAD --stat`
105
- !`git log main...HEAD --oneline`
106
- ```
107
-
108
- **Load bead context (if provided):**
109
-
110
- ```
111
- !`br show $ARGUMENTS`
46
+ ```bash
47
+ git branch --show-current
48
+ git log main...HEAD --oneline
49
+ git diff main...HEAD --stat
112
50
  ```
113
51
 
114
- **Load artifacts:**
52
+ If bead ID provided:
115
53
 
54
+ ```bash
55
+ br show $ARGUMENTS
56
+ ls .beads/artifacts/$ARGUMENTS/
116
57
  ```
117
- !`ls .beads/artifacts/<bead-id>/ 2>/dev/null`
118
- !`cat .beads/artifacts/<bead-id>/spec.md 2>/dev/null | head -30`
119
- !`cat .beads/artifacts/<bead-id>/review.md 2>/dev/null | head -30`
120
- ```
121
-
122
- Extract from artifacts:
123
-
124
- - **Goal** from spec.md
125
- - **Changes Made** from review.md
126
- - **Estimation Accuracy** from review.md
127
- - **Success Criteria** verification
128
58
 
129
- ## Phase 4: Review Before Push
59
+ Read the PRD to extract goal and success criteria for the PR description.
130
60
 
131
- Show what will be pushed:
61
+ ## Phase 3: Push and Confirm
132
62
 
133
- ```bash
134
- git log origin/$(git branch --show-current)..HEAD --oneline 2>/dev/null || git log --oneline -5
135
- git diff --stat origin/$(git branch --show-current)..HEAD 2>/dev/null || git diff --stat HEAD~3..HEAD
136
- ```
137
-
138
- **Use question tool to get push/PR decision:**
63
+ Show what will be pushed and ask the user:
139
64
 
140
65
  ```typescript
141
66
  question({
142
67
  questions: [
143
68
  {
144
69
  header: "Push",
145
- question: "Ready to push and create PR for $ARGUMENTS. What should I do?",
70
+ question: "Ready to push and create PR. Proceed?",
146
71
  options: [
147
- {
148
- label: "Push & create PR (Recommended)",
149
- description: "Push branch and create PR",
150
- },
72
+ { label: "Push & create PR (Recommended)", description: "Push branch and create PR" },
151
73
  { label: "Push & draft PR", description: "Create as draft for review" },
152
- {
153
- label: "Show diff first",
154
- description: "Review changes before pushing",
155
- },
156
- {
157
- label: "Skip (I'll push manually)",
158
- description: "Handle PR creation manually",
159
- },
74
+ { label: "Show diff first", description: "Review changes before pushing" },
160
75
  ],
161
76
  },
162
77
  ],
163
78
  });
164
79
  ```
165
80
 
166
- If user confirms, push:
81
+ If confirmed:
167
82
 
168
83
  ```bash
169
84
  git push -u origin $(git branch --show-current)
170
85
  ```
171
86
 
172
- ## Phase 5: Create PR
173
-
174
- Generate PR content from context:
87
+ ## Phase 4: Create PR
175
88
 
176
89
  ```bash
177
- gh pr create --title "<title>" --body "$(cat <<'EOF' # Keep as instructional (multi-line)
90
+ gh pr create --title "<title>" --body "$(cat <<'EOF'
178
91
  ## Summary
179
92
 
180
- [1-2 sentence description of what this PR does and why]
93
+ [1-2 sentences: what this PR does and why]
181
94
 
182
95
  ## Changes
183
96
 
184
- | File | Change |
185
- | ---- | ------ |
186
- | `src/foo.ts` | [description] |
187
- | `src/bar.ts` | [description] |
97
+ - `file.ts`: [what changed]
98
+ - `other.ts`: [what changed]
188
99
 
189
100
  ## Testing
190
101
 
191
- **Automated:**
192
- - All tests pass
193
- - Lint passes
194
- - Type check passes ✓
195
-
196
- **Manual verification:**
197
- - [ ] [How to test manually]
198
-
199
- ## Screenshots
200
-
201
- [If UI changes, include before/after screenshots]
202
-
203
- ## Estimation
204
-
205
- | Metric | Value |
206
- | ------ | ----- |
207
- | Estimated | [S/M/L] (~N calls) |
208
- | Actual | N calls |
209
- | Accuracy | [+/-N%] |
102
+ - All tests pass
103
+ - Lint and typecheck pass
104
+ - Manual verification: [how to test]
210
105
 
211
106
  ## Checklist
212
107
 
213
108
  - [x] Tests added/updated
214
109
  - [x] All gates pass
215
110
  - [ ] Docs updated (if applicable)
216
- - [ ] Breaking changes documented (if any)
217
-
218
- ## Artifacts
219
-
220
- - [spec.md](.beads/artifacts/<bead-id>/spec.md)
221
- - [review.md](.beads/artifacts/<bead-id>/review.md)
222
- [- research.md, plan.md, adr.md if they exist]
223
-
224
- ## Bead Reference
225
-
226
- Closes: <bead-id>
227
111
  EOF
228
112
  )"
229
113
  ```
230
114
 
231
- **For draft PRs (--draft):**
232
-
233
- ```bash
234
- gh pr create --draft --title "<title>" --body "..." # Keep as-is (instructional)
235
- ```
236
-
237
- ## Phase 6: Wait for CI (if --wait)
238
-
239
- ```
240
- !`gh pr checks --watch`
241
- ```
242
-
243
- Report CI status:
115
+ If `--draft`, add `--draft` flag.
244
116
 
245
- ```
246
- CI Status:
247
- ━━━━━━━━━━
248
-
249
- - build: [✓/✗/pending]
250
- - test: [✓/✗/pending]
251
- - lint: [✓/✗/pending]
252
-
253
- [If all pass] CI passed ✓
254
- [If any fail] CI failed: [which check]
255
- ```
256
-
257
- ## Phase 7: Update Bead & Sync
258
-
259
- ```bash
260
- br sync --flush-only
261
- ```
117
+ If bead ID provided, add artifacts section linking to `.beads/artifacts/$ARGUMENTS/prd.md`.
262
118
 
263
119
  ## Output
264
120
 
265
- ```
266
- PR Created: <bead-id>
267
- ━━━━━━━━━━━━━━━━━━━━
121
+ Report:
268
122
 
269
- URL: <pr-url>
270
- Status: [Ready for Review / Draft]
271
- Branch: <branch> → main
123
+ 1. PR URL
124
+ 2. Status (Ready for Review / Draft)
125
+ 3. Branch → main
126
+ 4. Gate results
272
127
 
273
- Pre-PR Gates: All passed ✓
274
- Conflicts: None ✓
275
- [CI: Passed ✓ (if --wait)]
276
-
277
- Artifacts linked:
278
- - spec.md ✓
279
- - review.md ✓
280
- [- research.md, plan.md, adr.md]
281
- ```
128
+ ## Related Commands
282
129
 
283
- **Next steps:**
284
-
285
- ```
286
- ━━━━━━━━━━━━━━━━━━━━
287
-
288
- Request review:
289
- gh pr edit <pr-number> --add-reviewer <username>
290
-
291
- Check CI:
292
- gh pr checks
293
-
294
- Merge when approved:
295
- gh pr merge --squash
296
- ```
297
-
298
- **If draft PR:**
299
-
300
- ```
301
- Draft PR created. When ready:
302
- gh pr ready
303
- ```
130
+ | Need | Command |
131
+ | ------------ | -------------- |
132
+ | Ship first | `/ship <id>` |
133
+ | Verify first | `/verify <id>` |