opencode-ship 0.9.0 → 0.10.0-rc.17

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 (137) hide show
  1. package/CHANGELOG.md +96 -0
  2. package/README.md +3 -1
  3. package/THIRD_PARTY_NOTICES.md +77 -19
  4. package/assets/agents/ship-controller.md +122 -0
  5. package/assets/agents/ship-final-spec-reviewer.md +87 -0
  6. package/assets/agents/ship-final-standards-reviewer.md +83 -0
  7. package/assets/agents/ship-planner.md +78 -0
  8. package/assets/agents/ship-task-builder.md +91 -0
  9. package/assets/agents/ship-task-reviewer.md +78 -0
  10. package/assets/commands/ship-deliver.md +30 -0
  11. package/assets/commands/ship-resume.md +28 -0
  12. package/assets/commands/ship-status.md +25 -0
  13. package/assets/skills/brainstorming/SKILL.md +160 -0
  14. package/assets/skills/brainstorming/spec-document-reviewer-prompt.md +49 -0
  15. package/assets/skills/brainstorming/visual-companion.md +298 -0
  16. package/assets/skills/code-review/SKILL.md +98 -0
  17. package/assets/skills/codebase-design/DEEPENING.md +37 -0
  18. package/assets/skills/codebase-design/DESIGN-IT-TWICE.md +44 -0
  19. package/assets/skills/codebase-design/SKILL.md +123 -0
  20. package/assets/skills/dispatching-parallel-agents/SKILL.md +176 -0
  21. package/assets/skills/domain-modeling/ADR-FORMAT.md +47 -0
  22. package/assets/skills/domain-modeling/CONTEXT-FORMAT.md +60 -0
  23. package/assets/skills/domain-modeling/SKILL.md +83 -0
  24. package/assets/skills/engineering-workflow/SKILL.md +125 -0
  25. package/assets/skills/engineering-workflow/domain.md +51 -0
  26. package/assets/skills/engineering-workflow/issue-tracker-github.md +45 -0
  27. package/assets/skills/engineering-workflow/issue-tracker-gitlab.md +46 -0
  28. package/assets/skills/engineering-workflow/issue-tracker-local.md +30 -0
  29. package/assets/skills/engineering-workflow/triage-labels.md +15 -0
  30. package/assets/skills/executing-plans/SKILL.md +73 -0
  31. package/assets/skills/grill-with-docs/SKILL.md +10 -14
  32. package/assets/skills/grilling/SKILL.md +21 -0
  33. package/assets/skills/handoff/SKILL.md +25 -0
  34. package/assets/skills/prototype/LOGIC.md +79 -0
  35. package/assets/skills/prototype/SKILL.md +35 -0
  36. package/assets/skills/prototype/UI.md +112 -0
  37. package/assets/skills/receiving-code-review/SKILL.md +214 -0
  38. package/assets/skills/requesting-code-review/SKILL.md +104 -0
  39. package/assets/skills/requesting-code-review/code-reviewer.md +172 -0
  40. package/assets/skills/research/SKILL.md +21 -0
  41. package/assets/skills/setup-engineering-workflow/SKILL.md +125 -0
  42. package/assets/skills/setup-engineering-workflow/domain.md +51 -0
  43. package/assets/skills/setup-engineering-workflow/issue-tracker-github.md +45 -0
  44. package/assets/skills/setup-engineering-workflow/issue-tracker-gitlab.md +46 -0
  45. package/assets/skills/setup-engineering-workflow/issue-tracker-local.md +30 -0
  46. package/assets/skills/setup-engineering-workflow/triage-labels.md +15 -0
  47. package/assets/skills/subagent-driven-development/SKILL.md +512 -0
  48. package/assets/skills/subagent-driven-development/implementer-prompt.md +142 -0
  49. package/assets/skills/subagent-driven-development/re-review-prompt.md +106 -0
  50. package/assets/skills/subagent-driven-development/task-reviewer-prompt.md +185 -0
  51. package/assets/skills/systematic-debugging/CREATION-LOG.md +119 -0
  52. package/assets/skills/systematic-debugging/SKILL.md +292 -0
  53. package/assets/skills/systematic-debugging/condition-based-waiting-example.ts +158 -0
  54. package/assets/skills/systematic-debugging/condition-based-waiting.md +115 -0
  55. package/assets/skills/systematic-debugging/defense-in-depth.md +122 -0
  56. package/assets/skills/systematic-debugging/find-polluter.sh +72 -0
  57. package/assets/skills/systematic-debugging/root-cause-tracing.md +169 -0
  58. package/assets/skills/systematic-debugging/test-academic.md +14 -0
  59. package/assets/skills/systematic-debugging/test-pressure-1.md +58 -0
  60. package/assets/skills/systematic-debugging/test-pressure-2.md +68 -0
  61. package/assets/skills/systematic-debugging/test-pressure-3.md +69 -0
  62. package/assets/skills/test-driven-development/SKILL.md +329 -0
  63. package/assets/skills/test-driven-development/writing-good-tests.md +198 -0
  64. package/assets/skills/to-spec/SKILL.md +84 -0
  65. package/assets/skills/to-tickets/SKILL.md +114 -0
  66. package/assets/skills/triage/AGENT-BRIEF.md +207 -0
  67. package/assets/skills/triage/OUT-OF-SCOPE.md +105 -0
  68. package/assets/skills/triage/SKILL.md +114 -15
  69. package/assets/skills/verification-before-completion/SKILL.md +129 -0
  70. package/assets/skills/wayfinder/SKILL.md +137 -0
  71. package/assets/skills/writing-plans/SKILL.md +177 -0
  72. package/assets/skills/writing-plans/plan-document-reviewer-prompt.md +49 -0
  73. package/dist/cli.js +1146 -435
  74. package/dist/core.js +210 -61
  75. package/dist/plugin.js +2368 -230
  76. package/package.json +3 -1
  77. package/schema/ship-config.schema.json +63 -2
  78. package/schema/ship-lock.schema.json +5 -3
  79. package/tests/plugin/plugin-load.test.mjs +85 -0
  80. package/vendor/mattpocock/LICENSE +30 -0
  81. package/vendor/obra/LICENSE +30 -0
  82. package/vendor/sources.json +976 -0
  83. package/vendor/superpowers/LICENSE +30 -0
  84. package/vendor/upstreams/mattpocock/skills/engineering/code-review/SKILL.md +89 -0
  85. package/vendor/upstreams/mattpocock/skills/engineering/codebase-design/DEEPENING.md +37 -0
  86. package/vendor/upstreams/mattpocock/skills/engineering/codebase-design/DESIGN-IT-TWICE.md +44 -0
  87. package/vendor/upstreams/mattpocock/skills/engineering/codebase-design/SKILL.md +114 -0
  88. package/vendor/upstreams/mattpocock/skills/engineering/domain-modeling/ADR-FORMAT.md +47 -0
  89. package/vendor/upstreams/mattpocock/skills/engineering/domain-modeling/CONTEXT-FORMAT.md +60 -0
  90. package/vendor/upstreams/mattpocock/skills/engineering/domain-modeling/SKILL.md +74 -0
  91. package/vendor/upstreams/mattpocock/skills/engineering/grill-with-docs/SKILL.md +7 -0
  92. package/vendor/upstreams/mattpocock/skills/engineering/prototype/LOGIC.md +79 -0
  93. package/vendor/upstreams/mattpocock/skills/engineering/prototype/SKILL.md +26 -0
  94. package/vendor/upstreams/mattpocock/skills/engineering/prototype/UI.md +112 -0
  95. package/vendor/upstreams/mattpocock/skills/engineering/research/SKILL.md +12 -0
  96. package/vendor/upstreams/mattpocock/skills/engineering/setup-matt-pocock-skills/SKILL.md +116 -0
  97. package/vendor/upstreams/mattpocock/skills/engineering/setup-matt-pocock-skills/domain.md +51 -0
  98. package/vendor/upstreams/mattpocock/skills/engineering/setup-matt-pocock-skills/issue-tracker-github.md +45 -0
  99. package/vendor/upstreams/mattpocock/skills/engineering/setup-matt-pocock-skills/issue-tracker-gitlab.md +46 -0
  100. package/vendor/upstreams/mattpocock/skills/engineering/setup-matt-pocock-skills/issue-tracker-local.md +30 -0
  101. package/vendor/upstreams/mattpocock/skills/engineering/setup-matt-pocock-skills/triage-labels.md +15 -0
  102. package/vendor/upstreams/mattpocock/skills/engineering/to-spec/SKILL.md +75 -0
  103. package/vendor/upstreams/mattpocock/skills/engineering/to-tickets/SKILL.md +105 -0
  104. package/vendor/upstreams/mattpocock/skills/engineering/triage/AGENT-BRIEF.md +207 -0
  105. package/vendor/upstreams/mattpocock/skills/engineering/triage/OUT-OF-SCOPE.md +105 -0
  106. package/vendor/upstreams/mattpocock/skills/engineering/triage/SKILL.md +112 -0
  107. package/vendor/upstreams/mattpocock/skills/engineering/wayfinder/SKILL.md +128 -0
  108. package/vendor/upstreams/mattpocock/skills/productivity/grilling/SKILL.md +12 -0
  109. package/vendor/upstreams/mattpocock/skills/productivity/handoff/SKILL.md +16 -0
  110. package/vendor/upstreams/obra/skills/brainstorming/SKILL.md +151 -0
  111. package/vendor/upstreams/obra/skills/brainstorming/spec-document-reviewer-prompt.md +49 -0
  112. package/vendor/upstreams/obra/skills/brainstorming/visual-companion.md +298 -0
  113. package/vendor/upstreams/obra/skills/dispatching-parallel-agents/SKILL.md +167 -0
  114. package/vendor/upstreams/obra/skills/executing-plans/SKILL.md +64 -0
  115. package/vendor/upstreams/obra/skills/receiving-code-review/SKILL.md +205 -0
  116. package/vendor/upstreams/obra/skills/requesting-code-review/SKILL.md +95 -0
  117. package/vendor/upstreams/obra/skills/requesting-code-review/code-reviewer.md +172 -0
  118. package/vendor/upstreams/obra/skills/subagent-driven-development/SKILL.md +503 -0
  119. package/vendor/upstreams/obra/skills/subagent-driven-development/implementer-prompt.md +142 -0
  120. package/vendor/upstreams/obra/skills/subagent-driven-development/re-review-prompt.md +106 -0
  121. package/vendor/upstreams/obra/skills/subagent-driven-development/task-reviewer-prompt.md +185 -0
  122. package/vendor/upstreams/obra/skills/systematic-debugging/CREATION-LOG.md +119 -0
  123. package/vendor/upstreams/obra/skills/systematic-debugging/SKILL.md +283 -0
  124. package/vendor/upstreams/obra/skills/systematic-debugging/condition-based-waiting-example.ts +158 -0
  125. package/vendor/upstreams/obra/skills/systematic-debugging/condition-based-waiting.md +115 -0
  126. package/vendor/upstreams/obra/skills/systematic-debugging/defense-in-depth.md +122 -0
  127. package/vendor/upstreams/obra/skills/systematic-debugging/find-polluter.sh +72 -0
  128. package/vendor/upstreams/obra/skills/systematic-debugging/root-cause-tracing.md +169 -0
  129. package/vendor/upstreams/obra/skills/systematic-debugging/test-academic.md +14 -0
  130. package/vendor/upstreams/obra/skills/systematic-debugging/test-pressure-1.md +58 -0
  131. package/vendor/upstreams/obra/skills/systematic-debugging/test-pressure-2.md +68 -0
  132. package/vendor/upstreams/obra/skills/systematic-debugging/test-pressure-3.md +69 -0
  133. package/vendor/upstreams/obra/skills/test-driven-development/SKILL.md +320 -0
  134. package/vendor/upstreams/obra/skills/test-driven-development/writing-good-tests.md +198 -0
  135. package/vendor/upstreams/obra/skills/verification-before-completion/SKILL.md +120 -0
  136. package/vendor/upstreams/obra/skills/writing-plans/SKILL.md +168 -0
  137. package/vendor/upstreams/obra/skills/writing-plans/plan-document-reviewer-prompt.md +49 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-ship",
3
- "version": "0.9.0",
3
+ "version": "0.10.0-rc.17",
4
4
  "private": false,
5
5
  "description": "npm-distributed OpenCode installer that materializes the delivery plugin, reviewer/verifier agents, skills, ship config and lock into any consumer repository.",
6
6
  "license": "MIT",
@@ -47,6 +47,8 @@
47
47
  "assets",
48
48
  "schema",
49
49
  "docs",
50
+ "vendor",
51
+ "tests/plugin/plugin-load.test.mjs",
50
52
  "THIRD_PARTY_NOTICES.md",
51
53
  "README.md",
52
54
  "CHANGELOG.md",
@@ -6,7 +6,7 @@
6
6
  "required": ["schemaVersion"],
7
7
  "additionalProperties": false,
8
8
  "properties": {
9
- "schemaVersion": { "const": 1 },
9
+ "schemaVersion": { "enum": [1, 2] },
10
10
  "profile": {
11
11
  "type": "string",
12
12
  "enum": ["core", "engineering"],
@@ -136,6 +136,67 @@
136
136
  "agentsDir": { "type": "string", "pattern": "^\\.opencode/agents/?$" },
137
137
  "skillsDir": { "type": "string", "pattern": "^\\.opencode/skills/?$" }
138
138
  }
139
+ },
140
+ "workflow": {
141
+ "type": "object",
142
+ "description": "Required when profile is engineering. Ignored when profile is core.",
143
+ "additionalProperties": false,
144
+ "properties": {
145
+ "models": {
146
+ "type": "object",
147
+ "additionalProperties": false,
148
+ "required": ["planner", "builder", "finalReviewer"],
149
+ "properties": {
150
+ "planner": {
151
+ "type": "string",
152
+ "pattern": "^[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+$",
153
+ "description": "Provider/model id for the strong planning child session."
154
+ },
155
+ "builder": {
156
+ "type": "string",
157
+ "pattern": "^[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+$",
158
+ "description": "Provider/model id for the cheap builder child session."
159
+ },
160
+ "finalReviewer": {
161
+ "type": "string",
162
+ "pattern": "^[A-Za-z0-9_.-]+/[A-Za-z0-9_.-]+$",
163
+ "description": "Provider/model id for the final Standards + Spec reviewers."
164
+ }
165
+ }
166
+ },
167
+ "approval": {
168
+ "type": "object",
169
+ "additionalProperties": false,
170
+ "properties": {
171
+ "mirrorToIssue": { "const": true },
172
+ "maxFailedRounds": { "const": 3 }
173
+ }
174
+ }
175
+ }
176
+ }
177
+ },
178
+ "allOf": [
179
+ {
180
+ "if": {
181
+ "required": ["profile"],
182
+ "properties": { "profile": { "const": "engineering" } }
183
+ },
184
+ "then": {
185
+ "required": ["workflow"],
186
+ "properties": {
187
+ "workflow": {
188
+ "required": ["models", "approval"],
189
+ "properties": {
190
+ "models": {
191
+ "required": ["planner", "builder", "finalReviewer"]
192
+ },
193
+ "approval": {
194
+ "required": ["mirrorToIssue", "maxFailedRounds"]
195
+ }
196
+ }
197
+ }
198
+ }
199
+ }
139
200
  }
140
- }
201
+ ]
141
202
  }
@@ -6,13 +6,13 @@
6
6
  "required": ["contractVersion", "manager", "files", "integrity"],
7
7
  "additionalProperties": false,
8
8
  "properties": {
9
- "contractVersion": { "enum": [1, 2] },
9
+ "contractVersion": { "enum": [1, 2, 3] },
10
10
  "manager": {
11
11
  "type": "object",
12
12
  "required": ["schemaVersion", "name", "version", "appliedAt", "config"],
13
13
  "additionalProperties": false,
14
14
  "properties": {
15
- "schemaVersion": { "enum": [1, 2] },
15
+ "schemaVersion": { "enum": [1, 2, 3] },
16
16
  "name": { "type": "string", "pattern": "^opencode-ship$" },
17
17
  "version": { "type": "string", "minLength": 1 },
18
18
  "templateSet": { "type": "string", "minLength": 1 },
@@ -44,14 +44,16 @@
44
44
  "type": "array",
45
45
  "items": {
46
46
  "type": "object",
47
- "required": ["pointer", "strategy"],
47
+ "required": ["pointer", "strategy", "scope", "installedSha256", "previous"],
48
48
  "additionalProperties": false,
49
49
  "properties": {
50
50
  "pointer": { "type": "string", "pattern": "^/" },
51
51
  "strategy": { "enum": ["value", "object-entry", "array-member"] },
52
+ "scope": { "enum": ["core", "engineering"] },
52
53
  "installedSha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" },
53
54
  "previous": {
54
55
  "type": "object",
56
+ "required": ["existed"],
55
57
  "additionalProperties": true,
56
58
  "properties": {
57
59
  "existed": { "type": "boolean" },
@@ -0,0 +1,85 @@
1
+ /*
2
+ * Plugin loading smoke test.
3
+ *
4
+ * Exercises the compiled bundle against the @opencode-ai/plugin
5
+ * runtime types without booting OpenCode. It verifies:
6
+ * - the bundled plugin is the default-exported function
7
+ * - calling it returns an object with a `tool` key
8
+ * - the `tool` object exposes exactly the 24 named tool
9
+ * definitions (9 delivery + 7 control-plane + 8 workflow)
10
+ */
11
+
12
+ import test from "node:test";
13
+ import assert from "node:assert/strict";
14
+ import { pathToFileURL } from "node:url";
15
+ import { resolve } from "node:path";
16
+
17
+ const pluginPath = pathToFileURL(resolve("dist/plugin.js")).href;
18
+
19
+ const EXPECTED_TOOLS = [
20
+ "delivery_cleanup",
21
+ "delivery_github_read",
22
+ "delivery_inspect",
23
+ "delivery_issue",
24
+ "delivery_issue_close",
25
+ "delivery_issue_comment",
26
+ "delivery_issue_labels",
27
+ "delivery_issue_link",
28
+ "delivery_merge",
29
+ "delivery_pr",
30
+ "delivery_publish",
31
+ "delivery_ready",
32
+ "delivery_review",
33
+ "delivery_sync",
34
+ "delivery_verify",
35
+ "delivery_worktree",
36
+ "ship_plan_approve",
37
+ "ship_plan_start",
38
+ "ship_plan_submit",
39
+ "ship_resume",
40
+ "ship_run_start",
41
+ "ship_status",
42
+ "ship_task_report",
43
+ "ship_task_review",
44
+ ];
45
+
46
+ test("plugin: default export is a function", async () => {
47
+ const mod = await import(pluginPath);
48
+ assert.equal(typeof mod.default, "function");
49
+ assert.equal(typeof mod.ShipPlugin, "function");
50
+ });
51
+
52
+ test("plugin: registers exactly 24 tools", async () => {
53
+ const mod = await import(pluginPath);
54
+ const fakeCtx = {
55
+ worktree: process.cwd(),
56
+ project: { worktree: process.cwd() },
57
+ client: {},
58
+ directory: process.cwd(),
59
+ };
60
+ const result = await mod.default(fakeCtx);
61
+ assert.ok(result.tool, "result.tool should exist");
62
+ const ids = Object.keys(result.tool).sort();
63
+ assert.deepEqual(ids, EXPECTED_TOOLS, `expected 24 tools, got ${ids.length}: ${ids.join(", ")}`);
64
+ for (const id of ids) {
65
+ assert.equal(typeof result.tool[id].execute, "function", `${id} should expose an execute function`);
66
+ assert.equal(typeof result.tool[id].description, "string", `${id} should expose a description`);
67
+ }
68
+ });
69
+
70
+ test("plugin: every tool returns a contract-version-2 envelope", async () => {
71
+ const mod = await import(pluginPath);
72
+ const fakeCtx = {
73
+ worktree: process.cwd(),
74
+ project: { worktree: process.cwd() },
75
+ client: {},
76
+ directory: process.cwd(),
77
+ };
78
+ const result = await mod.default(fakeCtx);
79
+ for (const id of Object.keys(result.tool)) {
80
+ const raw = await result.tool[id].execute({}, fakeCtx);
81
+ const parsed = JSON.parse(raw);
82
+ assert.equal(parsed.contractVersion, 2, `${id} must return contract-version-2 envelope`);
83
+ assert.ok(typeof parsed.kind === "string", `${id} must include a kind`);
84
+ }
85
+ });
@@ -0,0 +1,30 @@
1
+ # Matt Pocock's MIT license (vendor reference)
2
+
3
+ The full MIT text is reproduced below for the convenience of
4
+ `prepack` and human reviewers. The actual canonical text is the
5
+ one shipped in the upstream Matt Pocock repository at the SHA
6
+ pinned in `vendor/sources.json`.
7
+
8
+ ```
9
+ MIT License
10
+
11
+ Copyright (c) Matt Pocock and contributors
12
+
13
+ Permission is hereby granted, free of charge, to any person obtaining a copy
14
+ of this software and associated documentation files (the "Software"), to deal
15
+ in the Software without restriction, including without limitation the rights
16
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
17
+ copies of the Software, and to permit persons to whom the Software is
18
+ furnished to do so, subject to the following conditions:
19
+
20
+ The above copyright notice and this permission notice shall be included in all
21
+ copies or substantial portions of the Software.
22
+
23
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
24
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
26
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
28
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
29
+ SOFTWARE.
30
+ ```
@@ -0,0 +1,30 @@
1
+ # Superpowers MIT license (vendor reference)
2
+
3
+ The full MIT text is reproduced below for the convenience of
4
+ `prepack` and human reviewers. The actual canonical text is the
5
+ one shipped in the upstream obra/superpowers repository at the SHA
6
+ pinned in `vendor/sources.json`.
7
+
8
+ ```
9
+ MIT License
10
+
11
+ Copyright (c) obra and contributors
12
+
13
+ Permission is hereby granted, free of charge, to any person obtaining a copy
14
+ of this software and associated documentation files (the "Software"), to deal
15
+ in the Software without restriction, including without limitation the rights
16
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
17
+ copies of the Software, and to permit persons to whom the Software is
18
+ furnished to do so, subject to the following conditions:
19
+
20
+ The above copyright notice and this permission notice shall be included in all
21
+ copies or substantial portions of the Software.
22
+
23
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
24
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
26
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
28
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
29
+ SOFTWARE.
30
+ ```