diff options
| author | Drew Ritter <drew@primeradiant.com> | 2026-09-17 18:27:50 -0700 |
|---|---|---|
| committer | Drew Ritter <drew@primeradiant.com> | 2026-09-17 18:27:50 -0700 |
| commit | 1eae439437a3fbcb892529a4a777bded256d2e2b (patch) | |
| tree | eb86f801e15942a6b39bfacca2cac7b966acf934 /.opencode/plugins | |
| parent | 2c4dcd851a851633ee9037954cd3a20769cdf8b9 (diff) | |
docs(opencode): describe supported V2 setup and bootstrap behavior
Diffstat (limited to '.opencode/plugins')
| -rw-r--r-- | .opencode/plugins/superpowers.js | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/.opencode/plugins/superpowers.js b/.opencode/plugins/superpowers.js index 7305470..5ded2f5 100644 --- a/.opencode/plugins/superpowers.js +++ b/.opencode/plugins/superpowers.js @@ -60,7 +60,7 @@ const extractAndStripFrontmatter = (content) => { }; // Tool mapping injected into the bootstrap, differentiated by host flavor. -// V1 (OpenCode 1.18.x) and V2 (OpenCode 2.x beta) expose different built-in +// V1 (OpenCode 1.18.x) and V2 (OpenCode 2.0.4/2.0.7) expose different built-in // tools, so each flavor's injection path picks its own constant below. // Exported for tests (tests/opencode/test-bootstrap-caching.mjs). @@ -82,16 +82,15 @@ Use OpenCode's native \`skill\` tool to list and load skills.`; // V2 built-ins: no todo tool at all; task → subagent (agent name in 'agent', // continuation via sessionID); apply_patch → patch (patchText, same patch // format); bash → shell. read, write, edit, grep, glob, webfetch, websearch, -// and skill all exist under those names (verified against the 2.0.3 tool -// catalog served by /api/plugin). +// and skill all exist under those names (verified against the 2.0.4 and 2.0.7 +// host contracts). export const V2_MAPPING = `**Tool Mapping for OpenCode:** When skills request actions, substitute OpenCode equivalents: - Create or update todos → OpenCode v2 has no todo tool; track the plan in a markdown file (or the harness's plan facility) instead - \`Subagent (general-purpose):\` → \`subagent\` with \`agent: "general"\` (give it \`description\` and \`prompt\`, optionally \`background\`; pass \`sessionID\` to continue a previous subagent) - Invoke a skill → OpenCode's native \`skill\` tool - Read files → \`read\` -- Create or overwrite a file → \`write\` -- Edit files → \`edit\` for targeted changes, or \`patch\` with \`patchText\` (same patch format) when a skill speaks in patch format or deletes files +- Create, edit, or delete files → use \`patch\` with \`patchText\` when available; otherwise use \`write\` to create or overwrite files, \`edit\` for targeted changes, and \`shell\` for deletion - Run shell commands → \`shell\` (\`command\`, \`workdir\`, \`timeout\`, \`background\`) - Search files → \`grep\`, \`glob\` - Fetch a URL → \`webfetch\` |
