Skip to content

Latest commit

 

History

History
647 lines (556 loc) · 46.8 KB

AGENTS.md

File metadata and controls

647 lines (556 loc) · 46.8 KB

AGENTS.md

Instructions for coding agents (any harness) working in this repository, and the reference for its layout. CLAUDE.md imports this file. Devin also loads a plugin's root AGENTS.md as an always-on rule; that is accepted (see conflict 5), so keep this file free of anything a plugin user must not see.

What this repo is

A coding-agent plugin with four opencode v2 skills, made from rjstone/harness-plugin-template and shipped to every harness that template supports.

This plugin: opencode-dev

The plugin is named opencode-dev, the repo name without -plugin (the user, 2026-11-28); its skills show as opencode-dev:<skill>. Only gemini-extension.json carries the repo name. The opencode-api cache folder keeps the name opencode-dev-plugin, so existing caches still work. The template reference below the marker applies. The plugin ships four skills for opencode v2, moved here with their history from rjstone/agent-skills (the user, 2026-11-28):

  • opencode-build - opencode v2 Build docs (plugins, client, SDK) cached as Markdown in references/, with scripts/refresh_references.py to update them and ERRATA.md for known doc mistakes. Never hand-edit downloaded references/ pages (a test compares each with its hash in references/manifest.json). Our own additions go in references/X.local.md beside the page X.md they supplement. Maintenance details are in the skill's MAINTAINING.md.
  • opencode-cli - opencode v2 CLI docs (commands, cli.json, keybinds, themes, web UI, ACP) cached the same way, with its own refresh script copy and ERRATA.md.
  • opencode-api - the server's published OpenAPI spec, searched with scripts/api_lookup.py (too large to read whole). Not shipped (about 1 MB, over the Claude plugin directory's 256 KiB file limit): scripts/fetch_spec.py downloads it into a per-user cache on first use and re-checks it weekly (the user, 2026-11-28).
  • opencode-console - OpenCode Console docs cached like opencode-cli, with every dollar amount except $0 replaced by [check-api] at download; SKILL.md says how to look prices up live. Our own CLI.md and API.md sit beside SKILL.md, not in references/.

Rules carried over from agent-skills:

  • Skill frontmatter order: name, description ("Use when ..."), optional compatibility, license: MIT, metadata (author, source, quoted version, optional credits). metadata.source is this repo (before 2026-11-28 it was rjstone/agent-skills).
  • Bump a skill's metadata.version on every change to it (major: breaking; minor: new files or features; patch: fixes). A version a script reports lives in one place and never passes metadata.version.
  • Public repo: no secrets, account names, hostnames or home paths in any file.
  • Skill tests are stdlib unittest files tests/test_<skill>.py, each starting with if not selected("<skill>"): raise unittest.SkipTest(...) (tests/_select.py; SKILLS=a,b limits a run). Run python3 -m unittest discover -s tests. No network in tests.

Making a plugin from the template

  1. Create a repo from the template (rjstone/harness-plugin-template) and name it <name>-plugin, where <name> is the plugin's name (see "Name rule").
  2. Edit plugin.config.json: name (<name>; the generator refuses anything else for a -plugin repo, and Gemini's manifest gets the repo name by itself), displayName, description, shortDescription, author, URLs (repository decides the repo name), keywords, category, and harnesses (turn off what the plugin doesn't ship to).
  3. Replace skills/example/ with real skills, and assets/icon.png with the plugin's icon.
  4. Add optional parts (agents, hooks, MCP, code) from "Layout" below.
  5. node scripts/build.ts, then commit everything it wrote. CI fails if a generated file is stale (--check).
  6. Set ci.repo to your copy of the marketplace and rebuild (the default is rjstone's). Update README.md (install table, owner/repo, and the badge row's owner/repo).
  7. Put the repo's own checks in scripts/ci.sh (see "Checks"). It starts with the template's three; add yours below them.
  8. If the plugin is listed in rjstone/plugin-marketplace, set the variable MARKETPLACE_APP_CLIENT_ID and the secret MARKETPLACE_APP_PRIVATE_KEY in the repo's Actions settings. If it isn't, leave them unset (a release then skips the marketplace), set ci.notifyMarketplace to false and delete .github/workflows/notify-marketplace.yml (the generator never deletes it, and the drift list marks it optional).

Rules

  1. The repo root is the plugin. Harnesses that install from a git URL (Gemini's gallery, pi install git:, opencode plugin add github:, amp plugins add, cline plugin install, Kiro, Devin, npx skills add) handle a root plugin best; Gemini's gallery requires the manifest at the root.
  2. Harness-neutral content lives once, at the root: skills/, agents/, hooks/, mcp/, assets/. No per-harness copies and no symlinks (Windows needs admin rights for them).
  3. Harness-specific metadata goes where that harness looks: a dot folder (.claude-plugin/, .cursor-plugin/, ...), a root file (gemini-extension.json) or a reverse-domain folder (com.github.copilot/).
  4. Code only one harness runs goes where that harness loads it from the repo root when it can (.opencode/plugins/, .pi/extensions/, Hermes' root plugin.yaml), else in a top-level folder named after the harness (cline/, amp/).
  5. Never edit a generated file by hand ("gen" in the tree). Change plugin.config.json or the inputs and run node scripts/build.ts.
  6. One icon: assets/icon.png, square PNG, 512-2048 px, under 2 MB. Every icon field points at it (conflict 8).
  7. Public by default: no secrets, tokens or personal paths in any file. Hook and MCP programs read keys from the environment at run time.

Layout

Legend: core = in every plugin; gen = written by scripts/build.ts; opt = add when the plugin uses it; doc = described here only, not in the template.

.
├── plugin.config.json            core  single source of truth for metadata (see "Generator")
├── plugin.json                   gen   Agent Plugins 1.0 manifest + extensions["com.openai"] (Codex)
├── mcp.json                      gen   Agent Plugins MCP file ($schema, type, ${PLUGIN_ROOT}); needs mcp/servers.json
├── package.json                  gen   dev scripts; opencode "exports" and Pi "pi" key when those are on
├── skills/                       core  one folder per skill, no nesting
│   ├── <name>/SKILL.md                 Agent Skills spec; optional scripts/, references/, assets/
│   └── index.json                gen   opencode HTTP skill catalog
├── agents/                       opt   subagents, Claude-format Markdown (Claude, Cursor, Gemini,
│   └── <name>.md                       Augment, Devin, Qwen, Antigravity; Droid merges into droids/)
├── commands/                     opt   slash commands: <name>.md (Claude, Cursor, Augment, Qwen) and
│                                       <name>.toml (Gemini). Prefer skills: most harnesses show them as /commands
├── hooks/                        opt
│   ├── hooks.json                opt   Claude schema; Augment, Junie, Droid read it; Gemini reads its own schema here (conflict 3)
│   ├── hooks-cursor.json         opt   Cursor schema (version 1, camelCase events); the generator links it
│   ├── run-hook.cmd              opt   polyglot launcher: one file runs as a cmd.exe batch and in bash
│   └── <hook-name>               opt   the hook programs every config points at
├── rules/<name>.md               opt   Antigravity and Devin rules (trigger frontmatter); Cursor rules (.mdc ok)
├── mcp/
│   ├── servers.json              opt   neutral MCP list; the generator writes every MCP file from it
│   └── <server code>             opt
├── assets/icon.png               core
├── .claude-plugin/
│   ├── plugin.json               gen   Claude Code manifest (no `icon` key: see conflict 8)
│   ├── icon.png                  gen   copy of assets/icon.png (no Claude doc names this location [U])
│   └── marketplace.json          gen   one-plugin marketplace, source "./" (Claude, Copilot, Droid,
│                                       Augment, Junie; Codex reads it as a legacy location)
├── .mcp.json                     gen   Claude-format MCP (${CLAUDE_PLUGIN_ROOT}); Cursor, Droid, Augment, Devin read it
├── .cursor-plugin/plugin.json    gen   Cursor manifest; links .mcp.json and hooks/hooks-cursor.json
├── .antigravity-plugin/plugin.json gen Antigravity manifest
├── mcp_config.json               gen   Antigravity MCP file
├── gemini-extension.json         gen   Gemini CLI manifest (mcpServers inline; contextFileName if GEMINI.md exists)
├── GEMINI.md                     opt   Gemini CLI context file
├── com.github.copilot/           opt   Copilot CLI + VS Code extras for the Agent Plugins form
│   ├── agents/<name>.agent.md    gen   from agents/ (name and description only)
│   ├── commands/                 opt   hand-written
│   ├── hooks/hooks.json          opt   Copilot schema ({"version":1,"hooks":{"preToolUse":[...]}})
│   └── lsp.json                  opt
├── .kimi-plugin/plugin.json      gen   Kimi Code manifest
├── .muse-plugin/plugin.json      gen   Muse manifest (off by default; a root Agent Plugins plugin.json takes over)
├── index.js                      opt   opencode v2 directory-form entry: re-exports the plugin
├── .opencode/plugins/<name>.js   opt   opencode plugin, V1 + V2 in one dependency-free file
├── .pi/extensions/<name>.ts      opt   Pi extension (skills come from "pi.skills": ["./skills"])
├── plugin.yaml, __init__.py      opt   Hermes native plugin, at the root (its docs name no .hermes-plugin/)
├── cline/                        doc   Cline plugin (package.json "cline" key)
├── amp/                          doc   Amp plugin module (<name>/index.ts)
├── scripts/                      core  the generator (build.ts, generate.ts, types.ts, frontmatter.ts),
│                                       ci.sh (the repo's own checks), release.sh (makes a release's changes)
├── .tests/                       core  build.test.ts (generator tests; node:test, throwaway
│                                       folders, no network). A dot folder because `claude plugin
│                                       test .` runs every *.test.ts outside dot folders and
│                                       node_modules, and would fail on the node:test suite
├── tests/                        opt   the plugin's own tests, e.g. a mod's `claude plugin test`
│                                       files (not created empty)
├── .github/workflows/                  three thin callers of rjstone/plugin-marketplace's reusable workflows (gen, from the `ci` config)
│   ├── check.yml                 core  scripts/ci.sh, claude plugin validate, test counts; badges job
│   ├── release.yml               core  tag, GitHub Release and marketplace notice, from a release commit,
│   │                                   a manual run or a pushed vX.Y.Z tag
│   └── notify-marketplace.yml    opt   report a tag to rjstone/plugin-marketplace again, by hand
├── AGENTS.md, CLAUDE.md          core  CLAUDE.md is "@AGENTS.md" plus Claude-only notes
├── DESIGN.md                     core  quick reference: the generator, and the files each harness looks for
├── README.md                     core  ≥ 40 words (Claude directory check); install table
├── TODO.md                       core  open work and the [T] install tests
├── skills.sh.json                opt   groups for the repo's skills.sh page (hand-written)
├── CHANGELOG.md                  gen   git-cliff (not scripts/build.ts)
├── cliff.toml                    gen   git-cliff config; the commit link comes from `repository`
├── tsconfig.json, .gitignore     core
└── LICENSE                       core  MIT

Not generated, on purpose:

  • .codex-plugin/plugin.json: Codex prefers the root plugin.json, whose extensions["com.openai"] replaces .codex-plugin/plugin.json entirely (conflict 13).
  • .github/plugin/, .plugin/, a root marketplace.json: Copilot reads them before .claude-plugin/, and a root marketplace.json would take priority over Claude's for Copilot.
  • .factory-plugin/, .augment-plugin/, .devin-plugin/, .junie-extension/: those harnesses read .claude-plugin/ (Droid copies it to .factory-plugin/ itself).
  • qwen-extension.json: Qwen loads the Agent Plugins form natively and converts Gemini and Claude ones. Add it by hand only for Qwen-only features (channels, workflows).
  • .cursor-plugin/marketplace.json, .agents/plugins/marketplace.json: multi-plugin and Codex catalogs belong in rjstone/plugin-marketplace, which generates them.
  • skills.sh.json: optional and hand-written. npx skills needs no manifest to find skills/; this file only groups the skills on the repo's skills.sh page (titles, a sentence each, skill names), which is editorial, like the README; its paths are read by the CLI at install time. That skills.sh re-reads it when someone installs with npx skills add <owner>/<repo> is [U]. The template itself has none: its only skill is the placeholder.

Generator

TypeScript with no dependencies. Node ≥ 22.18 runs .ts directly by stripping types, so there is no build step. Keep scripts/*.ts to erasable syntax (no enum, namespace or parameter properties); tsconfig.json enforces it with erasableSyntaxOnly.

Command What it does
node scripts/build.ts (npm run build) writes every generated file; deletes generated files whose harness is off or whose input is gone
node scripts/build.ts --check (npm run check) exits 1 on a missing, stale or leftover generated file, or on a content error
--root <dir> run against another plugin folder
npm test generator tests (node --test .tests/*.test.ts; .tests/ so claude plugin test skips them)
npm run typecheck tsc strict (installs typescript and @types/node into the git-ignored node_modules)

Modules: types.ts (config shape, validateConfig, nameProblem), frontmatter.ts (SKILL.md and agent frontmatter), generate.ts (plan computes every file, diff compares, write applies), build.ts (command line).

plugin.config.json

Field Rules Used by
name see "Name rule"; for a repo named <x>-plugin it must be <x> every manifest except Gemini's
displayName ≤ 30 characters (Codex) Codex, Cursor, Antigravity, Kimi, Muse
version semver X.Y.Z; the only place the version is written every manifest, package.json
description ≤ 1024 characters every manifest; Codex longDescription
shortDescription ≤ 30 characters (Codex) Codex, Kimi
author {name, email?, url?} every manifest (Cursor: name and email only); Codex developerName
homepage, repository https:// URLs manifests, package.json, Codex websiteURL
license, keywords SPDX id; string list manifests (Pi adds pi-package)
icon path inside the repo copied to .claude-plugin/icon.png; Codex logo/composerIcon, Cursor and Antigravity logo
category e.g. Developer Tools Codex
harnesses one boolean per output group (below) which files exist
ci required {repo, ref, templateRepo?, fetchDepth?, notifyMarketplace?, pluginTests?}; repo/templateRepo are owner/repo, ref matches [\w./-]+ .github/workflows/check.yml, release.yml and (when notifyMarketplace) notify-marketplace.yml: the uses: lines, fetch-depth: (fetchDepth, a non-negative integer; 0 = full history), plugin-tests: true (pluginTests, a boolean; runs claude plugin test) and template-repo:
agentPlugins, codex, claude, claudeMarketplace, cursor, antigravity, gemini, kimi, muse, packageJson optional objects deep-merged into that one file (codex into extensions["com.openai"]); arrays are replaced, not merged
changelog optional {commitPreprocessors: [{pattern, replace}]} cliff.toml commit_preprocessors, e.g. to give a squash merge that kept GitHub's "Merge pull request" title its conventional title
harnesses key Files
agentPlugins plugin.json, mcp.json
claude .claude-plugin/plugin.json, marketplace.json, .mcp.json
cursor .cursor-plugin/plugin.json (and .mcp.json)
antigravity .antigravity-plugin/plugin.json, mcp_config.json
gemini gemini-extension.json
copilotExtras com.github.copilot/agents/*.agent.md
opencodeCatalog skills/index.json (needs metadata.version in every skill)
opencode package.json exports["."] = ./.opencode/plugins/<name>.js (must exist)
pi package.json pi key and pi-package keyword
kimi .kimi-plugin/plugin.json
muse .muse-plugin/plugin.json

package.json and cliff.toml are always written: package.json also carries the dev scripts, and cliff.toml's commit link comes from repository (plain commit ids when there is none).

mcp/servers.json

{ "servers": {
  "local":  { "type": "stdio", "command": "node", "args": ["{root}/mcp/server.js"], "env": { "CACHE": "{data}" } },
  "remote": { "type": "http", "url": "https://example.com/mcp", "headers": {} }
} }
  • command is one bare token (Agent Plugins doesn't expand variables in it): put paths in args.
  • {root} and {data} become each harness's variables (see "Variables"). Gemini has no data variable, so {data} is an error while gemini is on.
  • http servers become streamable-http (Agent Plugins), http (Claude), httpUrl (Gemini) and serverUrl (Antigravity).

Content checks

  • Skills: one folder per skill under skills/, each with SKILL.md; name equals the folder and passes the name rule; description 1-1024 characters; no nested SKILL.md (Agent Plugins 1.0 section 7.1: clients scan only skills/<name>/); metadata.version while the opencode catalog is on. Starting a description with "Use when" is house style, not checked and not a spec rule.
  • Agents: frontmatter with name and description.
  • The icon exists.
  • Naming: an error if the repo name (the last segment of repository) ends in -plugin and name isn't the repo name without that suffix.

Name rule

1-64 characters, ^[a-z0-9]+(-[a-z0-9]+)*$: lowercase letters, digits and single hyphens. No periods (Antigravity forbids them). Not claude, and not starting claude-, anthropic- or cc-plugin- (Claude rejects these). The same rule applies to skill names.

Repo rule: the repo name is the last path segment of repository (a trailing .git or / removed). If it ends in -plugin, name must be the repo name without that suffix, so the repo docshelf-plugin holds the plugin docshelf, and the generator reports anything else as an error. With no repository, or a repo name that doesn't end in -plugin, there is no rule.

Gemini exception: gemini-extension.json carries the repo name, not name. Gemini's reference says "we expect this name to match the extension directory name", and a cloned or linked extension folder is named after the repo. Gemini itself only checks ^[a-zA-Z0-9-]+$ and names the install folder after it. Qwen converts the same file. Every other manifest carries name.

The five format families

Family Harnesses What they read
A. Agent Plugins 1.0 Codex, Copilot CLI, VS Code, Cursor (skills + MCP only), Kiro, Qwen, Hermes, Devin, Antigravity (shadowed by its own file) root plugin.json with $schema, skills/<n>/SKILL.md, root mcp.json
B. Claude layout Claude Code; also Copilot CLI (legacy), VS Code, Droid, Augment, Junie (marketplace), Devin, npx skills, Qwen (converts) .claude-plugin/plugin.json + marketplace.json, components at the root
C. Own manifest file Cursor (full set), Antigravity, Gemini CLI, Qwen (native), Kimi Code, Muse .cursor-plugin/, .antigravity-plugin/, gemini-extension.json, qwen-extension.json, .kimi-plugin/, .muse-plugin/
D. Code packages opencode, Pi, Cline, Amp, Hermes (native) a package with its own entry point
E. Skills only npx skills, opencode HTTP skill catalog skills/, skills/index.json

Conflicts between harnesses, and how this layout resolves them

# Conflict Resolution
1 Copilot and VS Code read a root plugin.json without $schema as Copilot's legacy format. The root plugin.json is always strict Agent Plugins 1.0. Copilot then ignores .claude-plugin/, so Copilot extras go in com.github.copilot/ [T].
2 MCP: four file names, several variable spellings. Claude .mcp.json, Agent Plugins mcp.json ($schema, type), Antigravity mcp_config.json, Gemini inline. Cursor reads mcp.json but expands only ${CURSOR_PLUGIN_ROOT} / ${CLAUDE_PLUGIN_ROOT}. One mcp/servers.json; the generator writes each file. .cursor-plugin/plugin.json points Cursor at .mcp.json.
3 hooks/hooks.json has several schemas: Claude (also Augment, Junie, Droid), Cursor, Gemini (fixed path). hooks/hooks.json is Claude's schema; Cursor's go in hooks/hooks-cursor.json, linked from its manifest (superpowers does the same). Gemini reads hooks/hooks.json in its own schema (BeforeTool, AfterTool, SessionStart, ...), so the Claude file is mostly inert there: Gemini prints an "Invalid hook event name" warning for each event it doesn't know and never errors (its hookRegistry.ts).
4 A root hooks.json is claimed by four schemas: Agent Plugins 1.1 draft, Antigravity, Devin, Copilot legacy. No root hooks.json. Antigravity now documents its own root hooks.json (named groups; PreToolUse, PostToolUse, SessionStart, PreInvocation, PostInvocation, Stop) and Devin reads one too; both stay unsupported until Agent Plugins 1.1 is final and the schemas are compared.
5 Root AGENTS.md: Devin loads it as an always-on rule; Antigravity warns and ignores it; coding agents read it as dev instructions. Decided (the user, 2026-11-27): keep dev instructions here and accept that Devin users get them. superpowers does the same.
6 Agents: frontmatter differs (Claude model: sonnet, Antigravity model: flash, Copilot *.agent.md). agents/*.md in Claude format; Copilot copies keep only name and description. Antigravity documents only inherit, flash_lite, flash and pro for model, so a Claude model name there is probably unsupported [T].
7 Commands: Claude and Cursor read commands/*.md, Gemini commands/*.toml, Qwen both, Antigravity warns about commands/. Prefer skills. .md and .toml commands coexist without clashing.
8 Icon fields: Claude icon, Agent Plugins 1.1 assets/icon.png, Codex logo + composerIcon, Cursor, Antigravity (≥ 128 px) and Devin logo. One assets/icon.png for all. Claude documents an icon field read only by its directory listing; the template leaves it out because the claude.ai marketplace sync (Agent SDK) warns about it as an unknown key (2026-11-28), and keeps a generated copy at .claude-plugin/icon.png, a location no Claude doc names [U]. Cursor and Antigravity logo are written assets/icon.png (relative, no ./, as their docs and Cursor's official plugins show); Codex's ./assets/icon.png.
9 Cursor: precedence between a root plugin.json and .cursor-plugin/plugin.json is undocumented. [T]. If the root one wins, Cursor gets skills + MCP only.
10 Claude's skills manifest path adds to skills/; Cursor's replaces it. Never set skills in a manifest (Kimi's ./skills/ is the same folder).
11 Claude doesn't load a plugin's root CLAUDE.md; claude plugin validate may warn. Accept it: it's the dev-instruction file.
12 Codex discovers hooks/hooks.json by default and would load the Claude-schema file. The generator sets extensions["com.openai"].hooks to {}. Override it in codex to ship Codex hooks. The docs say any explicit hooks value replaces discovery but never show {} [T].
13 Codex: root plugin.json vs .codex-plugin/plugin.json. Docs prefer the root form; superpowers uses .codex-plugin/. Root form, per the docs [T].

Variables

Harness Plugin root Persistent data Where they expand
Agent Plugins (Codex, Copilot, Qwen, Hermes, Devin, VS Code; Kiro [U]) ${PLUGIN_ROOT} ${PLUGIN_DATA} MCP args, env, cwd; 1.1 hook args; also env vars
Claude Code ${CLAUDE_PLUGIN_ROOT} ${CLAUDE_PLUGIN_DATA} MCP, LSP, hooks, skill and agent bodies; ${user_config.KEY}
Cursor ${CURSOR_PLUGIN_ROOT}, ${CLAUDE_PLUGIN_ROOT} none MCP command, args, env, cwd
Antigravity ${PLUGIN_ROOT} ${PLUGIN_DATA} MCP only; hooks run with the plugin root as cwd
Gemini CLI, Qwen native ${extensionPath} none manifest, hooks/hooks.json; also ${workspacePath}, ${/}
Factory Droid DROID_PLUGIN_ROOT, CLAUDE_PLUGIN_ROOT DROID_PLUGIN_DATA, CLAUDE_PLUGIN_DATA bodies, MCP command, args, url
Augment Auggie ${AUGMENT_PLUGIN_ROOT}, ${CLAUDE_PLUGIN_ROOT} none hook commands
Junie ${JUNIE_EXTENSION_ROOT}, ${CLAUDE_PLUGIN_ROOT} none hooks
Copilot CLI PLUGIN_ROOT (+ COPILOT_ and CLAUDE_ aliases) PLUGIN_DATA stdio MCP only

Hook and MCP programs should find their files relative to themselves or from the environment, never from a hard-coded path.

Install commands

Harness Install from this repo
Claude Code /plugin marketplace add <owner>/<repo>, then /plugin install <name>@<name>
Codex codex plugin marketplace add <owner>/<repo>
Copilot CLI copilot plugin install <owner>/<repo>
VS Code setting chat.plugins.marketplaces: "<owner>/<repo>"
Cursor marketplace submission, or copy to ~/.cursor/plugins/local/<name>
Antigravity agy plugin install https://github.com/<owner>/<repo>
Gemini CLI gemini extensions install https://github.com/<owner>/<repo>; gallery: repo topic gemini-cli-extension
Qwen Code qwen extensions install <owner>/<repo>
Kiro Powers panel > Add Custom Power > repo URL
Factory Droid droid plugin marketplace add <owner>/<repo>, droid plugin install <name>@<name>
Augment Auggie auggie plugin marketplace add <owner>/<repo>
Junie CLI /extensions marketplace add <owner>/<repo>, /extensions install <name>
Devin devin plugins install <owner>/<repo>
Hermes hermes plugins install <owner>/<repo> (installs disabled)
Kimi Code /plugins install https://github.com/<owner>/<repo>
Muse muse plugins marketplace add <name> <owner>/<repo>, then muse plugins install <plugin>@<name>
opencode code: opencode plugin add github:<owner>/<repo>; skills only: add https://raw.githubusercontent.com/<owner>/<repo>/main/skills/ to skills in opencode.json
Pi pi install git:github.com/<owner>/<repo>@vX.Y.Z
Amp skills: amp skill add <owner>/<repo>; code plugin: amp plugins add <url>
Cline cline plugin install <git-url> (code plugin)
npx skills npx skills add <owner>/<repo>

Checks

CI is check.yml, a thin caller of the reusable check workflow in rjstone/plugin-marketplace (.github/workflows/plugin-check.yml; its docs are in ci/). On every push and pull request it runs bash scripts/ci.sh, then claude plugin validate in both profiles (--profile directory adds some of the plugin-directory checks, such as the README; the submission portal runs the full list), then the drift report (see "Staying in step with the template"). The marketplace's ci/README.md documents the inputs and the scripts/ci.sh contract; this file doesn't repeat them.

scripts/ci.sh holds the repo's own checks: npm test, node scripts/build.ts --check and npm run typecheck, plus whatever the plugin adds. Before committing, run bash scripts/ci.sh, claude plugin validate . and claude plugin validate . --profile directory. The script works with no environment set. In CI it also gets two variables:

  • CI_BASE_SHA: the pull request's base commit, else the commit before the push. Use it for checks that compare against the base, such as "a changed skill needs a version bump". It is all zeros on the first push of a branch, and with the default shallow checkout the commit it names is usually not in the clone. A check that compares against it must treat a missing or all-zero base as nothing to compare. A repo that needs the history sets ci.fetchDepth: 0 in plugin.config.json and rebuilds.
  • CI_BADGES: a file the script may append extra badge lines to (see "Badges").

No validator exists for Codex, Copilot, VS Code, Cursor, Gemini, Qwen, Kiro, Droid, Augment, Junie or Devin; agy plugin validate (Antigravity) and hermes plugins validate exist but aren't in scripts/ci.sh yet (TODO.md).

Badges

README badges are SVG files on the orphan branch badges, linked as https://raw.githubusercontent.com/<owner>/<repo>/badges/<name>.svg; no badge service is used (the user, 2026-11-28). The marketplace's shared CI renders them on pushes to the default branch, offline, and force-pushes them as the branch's only commit. check (the job's result), tests, version and license (from plugin.config.json) come for free. tests adds up the summaries in the log of scripts/ci.sh and the validation step: node:test, unittest and claude plugin test. A repo adds a badge by appending a name|label|message|color line to the file named by $CI_BADGES in scripts/ci.sh. A fifth field names a logo that the shared CI ships (githubactions, nvidia, python): python|python|3.x stdlib|blue|python. A new badge appears after the next push to the default branch; GitHub's image proxy can show an old one for a few minutes.

scripts/ci.sh appends a skills badge (the number of skills). The README's badge row keeps this order (the user, 2026-11-28): version, skills, skills.sh, check, tests, any badges of the plugin's own, license. Generated badges are the rule; a service badge is only for a figure that only the service has.

One badge is served by a service, on purpose (the user, 2026-11-28): the skills.sh badge, for a plugin whose skills are listed there. Add it to the README's badge row once the repo has a skills.sh page (the first npx skills add <owner>/<repo> with telemetry on creates it): [![skills.sh](https://skills.sh/b/<owner>/<repo>)](https://skills.sh/<owner>/<repo>). It shows the install count, and reads "resource not found" until skills.sh has counted installs for the repo. The template's own README has none: the template is not listed.

The workflow callers are generated from ci in plugin.config.json (repo, ref, optional templateRepo, notifyMarketplace) and reference <ci.repo>/.github/workflows/plugin-<name>.yml@<ci.ref> (rjstone/plugin-marketplace, main). notify-marketplace.yml is written only while notifyMarketplace is true and is never deleted by the generator. A pin to a SHA would bring back the same update in every plugin repo, and main has the same owner as the callers. Third-party actions are pinned to commit SHAs inside the shared CI, and nothing else is in this repo's workflows. Pass event values to scripts through env:, never by ${{ }} inside run:.

Staying in step with the template

A plugin made from the template keeps some files identical to the template's: the generator modules, their test (.tests/build.test.ts), tsconfig.json, the three workflow callers, CLAUDE.md, and this file from the template-reference marker to the end. The list and the script that compares them are not in the plugin: they live on the template's maintenance branch (scripts/template-files.txt and scripts/template-drift.sh).

  • In CI, check.yml passes template-repo to the shared workflow, which fetches that branch and runs the script after validation. It prints one warning per differing file and never fails a plugin's run. A plugin that should stop following the template removes that input.

  • To pull the template's versions in, run this from the plugin repo's root, then review the diff and commit it (leave out --apply for a report only):

    d=$(mktemp -d) && git clone -q --depth 1 -b maintenance https://github.com/rjstone/harness-plugin-template "$d" && bash "$d/scripts/template-drift.sh" --apply
  • Fix a shared file in the template first, then apply it in each plugin repo. A fix made only in a plugin repo is overwritten by the next --apply.

Commits, versions and releases

  • Conventional commits: feat:, fix:, docs:, refactor:, perf:, test:, chore:/ci:/build:, optional scope, ! or a BREAKING CHANGE: footer. git-cliff groups the changelog by these.
  • Commit straight to main unless a change wants review on a branch.
  • The version lives only in plugin.config.json; bump it there and rebuild.
  • CHANGELOG.md is generated: npx git-cliff@2.14.2 -o CHANGELOG.md, never by hand. So is cliff.toml (by scripts/build.ts, from repository); it skips merge commits.
  • Merge a release branch by fast-forward or a merge commit, never squash or rebase, so the tagged commit stays in main's history.

Releasing vX.Y.Z, either way:

  • From a clone (people and agents; no tag to push):
    1. bash scripts/release.sh X.Y.Z: sets version in plugin.config.json, rebuilds the generated files and regenerates CHANGELOG.md.
    2. Commit everything as chore(release): vX.Y.Z and push main, with that commit as the newest one of the push.
  • From GitHub: Actions > release > Run workflow, with bump (patch, minor or major) or an exact version. The workflow runs scripts/release.sh and pushes the release commit itself.

release.yml then does the rest: it checks the release commit (the version in its message equals the manifest's and is above the newest tag; CHANGELOG.md has a section for it), tags it vX.Y.Z, publishes a GitHub Release with git-cliff's notes and, if the variable MARKETPLACE_APP_CLIENT_ID and the secret MARKETPLACE_APP_PRIVATE_KEY are set in this repo's Actions settings, starts rjstone/plugin-marketplace's update job. A pushed commit that isn't a release commit shows the workflow as skipped. A vX.Y.Z tag pushed by hand is still published, and refused if it differs from version in the manifest. The marketplace's ci/README.md has the details.

Tags must be vX.Y.Z (the marketplace ignores other forms).

Checked against superpowers (obra/superpowers v7.0.2, 2026-11-03)

superpowers ships one skills library to Claude Code, Codex, Cursor, Antigravity, Devin, Kimi Code, Muse, Hermes, Gemini CLI, opencode and Pi from one repo root:

File What it shows
.claude-plugin/plugin.json, marketplace.json (source: "./") the Claude form; Copilot, VS Code, Droid, Augment and Junie use it too
.codex-plugin/plugin.json Codex legacy form: skills, hooks: {}, interface with composerIcon (SVG) and logo (PNG)
.agents/plugins/marketplace.json Codex catalog: source: {source: "url", url: "./"}, policy, category
.cursor-plugin/plugin.json skills, hooks: "./hooks/hooks-cursor.json"
.antigravity-plugin/plugin.json displayName, logo, suggestedPrompts; no hooks, MCP or agents
.devin-plugin/plugin.json Devin's own manifest (read before .claude-plugin/)
.kimi-plugin/plugin.json skills, sessionStart: {skill}, skillInstructions, interface
.muse-plugin/plugin.json, marketplace.json schemaVersion: 1, capabilities.skills[] by path, hooks as {id, event, command[], timeoutMs}
.hermes-plugin/plugin.yaml, __init__.py Hermes native plugin in a dot folder (not a location Hermes' docs name)
gemini-extension.json + GEMINI.md name, description, version, contextFileName
package.json + index.js + .opencode/plugins/superpowers.js opencode via main and the directory form; one dependency-free JS file for V1 and V2
package.json pi key + .pi/extensions/superpowers.ts Pi via keywords: ["pi-package"], pi.extensions, pi.skills
hooks/hooks.json, hooks-cursor.json, run-hook.cmd Claude hooks with ${CLAUDE_PLUGIN_ROOT} and a powershell variant; Cursor hooks with a relative command
.version-bump.json 12 files carry the version (this template generates them instead)

Not shown there: a root Agent Plugins plugin.json, mcp.json, agents, commands, com.github.copilot/, Kiro, native Qwen or Cline.

Harness reference (from the docs, 2026-11-27)

Agent Plugins 1.0 (agent-plugins.org; spec repo agentplugins/agent-plugins-spec)

  • plugin.json: $schema (required), name (required, 1-64, a-z0-9-.), version, description, author{name,email,url}, homepage, repository, license, keywords[], extensions{<reverse-domain>:{}}. Closed schema. 1.1.0 draft adds displayName, root hooks.json, assets/icon.png.
  • Fixed locations: skills/<n>/SKILL.md (no nesting), root mcp.json ($schema + mcpServers, each with type: stdio, streamable-http or sse), client folders named by namespace.

Claude Code (code.claude.com/docs/en/plugins/manifest-reference)

  • .claude-plugin/plugin.json: only name required; also version, description, author, license, keywords, icon, homepage, repository, userConfig, engines, dependencies, component overrides (skills adds; commands, agents, outputStyles, workflows replace; hooks, mcpServers, lspServers merge). Paths start with ./.
  • Defaults: skills/, commands/*.md, agents/*.md, hooks/hooks.json, .mcp.json, .lsp.json, output-styles/, workflows/*.js, themes/, monitors/monitors.json, bin/.
  • icon is a documented field, read only by Anthropic's directory listing (ignored at load).
  • Directory checks (claude.com/docs/plugins/pre-submission-checklist): README ≥ 40 words, licence, pinned npx/uvx, no binaries except images and fonts, files < 256 KiB, ≤ 512 files. Those are the submission portal's checks; --profile directory runs only some of them locally.

OpenAI Codex (developers.openai.com/plugins/build/plugins)

  • Root Agent Plugins plugin.json preferred; .codex-plugin/plugin.json is the fallback.
  • extensions["com.openai"]: interface{displayName ≤ 30, shortDescription ≤ 30, longDescription, developerName, category, capabilities[], websiteURL, supportURL, privacyPolicyURL, termsOfServiceURL, defaultPrompt, brandColor, composerIcon, logo}, apps, hooks, onboardingSkill.
  • Hooks (hooks/hooks.json) work only for desktop plugins, after the user trusts them.

GitHub Copilot CLI (docs.github.com, cli-plugin-reference)

  • Agent Plugins root plugin.json first; legacy lookup .plugin/plugin.json, plugin.json, .github/plugin/plugin.json, .claude-plugin/plugin.json. Recognises the Agent Plugins 1.0.0 and 1.1.0 $schema ids.
  • Extras in com.github.copilot/: agents/*.agent.md, commands/, rules/, hooks/hooks.json, lsp.json.

VS Code agent plugins (code.visualstudio.com, agent-plugin-reference)

  • Detects Agent Plugins, Copilot, Claude and .plugin/ formats; adds automations/*.automation.md. Test a dev copy with the chat.pluginLocations setting.

Cursor (cursor.com/docs/reference/plugins)

  • .cursor-plugin/plugin.json: name required; description, version, author{name, email}, homepage, repository, license, keywords, logo (relative path such as assets/logo.svg, or a URL; no ..), rules, agents, skills, commands, hooks, mcpServers (every path field replaces discovery), variables. displayName is not on the reference page, but Cursor's official cursor/plugin-template sets it. cursor.com's docs now redirect to docs.grok.com (same content).
  • Defaults: rules/ (.md, .mdc), agents/, skills/, commands/, hooks/hooks.json, mcp.json (no dot, so .mcp.json is named in mcpServers). MCP expands ${CURSOR_PLUGIN_ROOT} and ${CLAUDE_PLUGIN_ROOT}. Local install: ~/.cursor/plugins/local/<name>/.

Google Antigravity (antigravity.google/docs/plugins)

  • .antigravity-plugin/plugin.json beats a root plugin.json. $schema https://antigravity.google/schemas/v1/plugin.json; name (no periods), displayName, description, version, logo, author (all required for the marketplace), suggestedPrompts, skills (adds folders), disabled, extensions.
  • mcp_config.json, agents/<n>.md, rules/, root hooks.json, assets/, scripts/. Ignored with warnings: .mcp.json, mcp.json, root AGENTS.md/GEMINI.md, hooks/hooks.json, commands/. Validator: agy plugin validate [--strict].
  • Root hooks.json has Antigravity's own schema (see conflict 4). mcp_config.json HTTP servers use serverUrl (url also works). Marketplace submission also wants suggestedPrompts (at most 3).

Gemini CLI (geminicli.com/docs/extensions/reference)

  • gemini-extension.json: name, version (required), description, mcpServers, contextFileName (default GEMINI.md), excludeTools, migratedTo, settings[], themes.
  • commands/*.toml (commands/a/b.toml is /a:b), skills/, agents/*.md, hooks/hooks.json (Gemini's own schema and event names), policies/*.toml; manifest also takes plan. HTTP MCP servers use httpUrl. Replaced by Antigravity CLI for unpaid users on 2026-06-18.

Qwen Code (qwenlm.github.io/qwen-code-docs)

  • Loads Agent Plugins natively (skills + MCP only); converts Gemini extensions and Claude plugins; native qwen-extension.json adds channels, workflows, commands, agents.

Kiro (kiro.dev/docs/powers)

  • Root Agent Plugins plugin.json (docs also require version, description, author, keywords); legacy POWER.md. Only skills/ and mcp.json.

Factory Droid (docs.factory.com/harness/plugins)

  • Reads .claude-plugin/; translates agents/ to droids/ and .mcp.json to mcp.json. Installs only through a marketplace (bare folders are rejected).

Augment Auggie (docs.augmentcode.com/cli/plugins)

  • .augment-plugin/ or .claude-plugin/; Claude layout for commands, agents, skills, hooks, .mcp.json.

JetBrains Junie CLI (junie.jetbrains.com/docs/junie-cli-extensions.html)

  • Marketplace .junie-extension/marketplace.json or .claude-plugin/marketplace.json; per-extension extension.json (undocumented); Claude-layout hooks.

Devin (docs.devin.ai/cli/extensibility/plugins/overview)

  • Lookup: .devin-plugin/plugin.json, .claude-plugin/plugin.json, root plugin.json. Loads root AGENTS.md as an always-on rule, rules/*.md, agents/, root hooks.json (Devin's own Claude-style format, not Agent Plugins 1.1), .mcp.json.

Hermes Agent (hermes-agent.nousresearch.com)

  • Native plugin.yaml + __init__.py register(ctx) at the plugin root (the docs name no .hermes-plugin/; which wins over a root plugin.json is [U]); also loads Agent Plugins packages (skills + mcp.json), installed disabled; its key under extensions is com.nousresearch.hermes. Validator: hermes plugins validate.

Kimi Code (kimi.com/code/docs/en/kimi-code-cli/customization/plugins)

  • Root kimi.plugin.json wins over .kimi-plugin/plugin.json. Name [A-Za-z0-9_-]+(\.[A-Za-z0-9_-]+)*. skills is needed to load skills/ (without it only a root SKILL.md is used); also skillInstructions, sessionStart, commands, mcpServers, hooks, systemPrompt/systemPromptPath; agents/ is found by default. interface: displayName, shortDescription, longDescription, developerName, websiteURL, mcpOverrides, skillOverrides, defaultLocale, locales (no capabilities).
  • Install: /plugins install https://github.com/<owner>/<repo> (also /tree/<ref>, /releases/tag/<tag>, /commit/<sha>).

Muse (meta-models.github.io/muse-code-sdk, guides/plugins)

  • .muse-plugin/plugin.json: schemaVersion (integer 1), name, compat.manifestDir (.muse-plugin), capabilities (skills and commands listed one by one as {id, path, enabledDefault?}; nothing is found by default). A root plugin.json with the exact Agent Plugins 1.0.0 $schema takes over, and .muse-plugin/plugin.json becomes an overlay whose name must match. Marketplaces: marketplace.json, .agents/plugins/marketplace.json, .claude-plugin/marketplace.json (no .muse-plugin/marketplace.json).

opencode v2 (opencode.ai/docs/build/plugins)

  • npm package; package.json exports (././server, ./tui, ./gui-experimental, ./rpc; no main is documented). A local folder without exports uses root server (else index), tui and rpc files. Everything registers in code in setup(ctx). HTTP skill catalog: index.json = {"skills":[{"name","version","files":[]}]}. Plugin authoring: rjstone/opencode-plugin-template.

Pi (earendil-works/pi, docs/packages.md)

  • package.json with keywords: ["pi-package"] and optional pi{extensions, skills, prompts, themes}; without it, conventional extensions/, skills/, prompts/, themes/. A pi key replaces that discovery for every type, so it must list everything the package ships. Host packages go in peerDependencies.

Cline (docs.cline.bot/customization/plugins)

  • package.json cline.plugins[{paths, capabilities}] (tools, commands, rules, messageBuilders, providers, automationEvents, hooks); the entry exports an AgentPlugin with setup(api, ctx). SDK and CLI only, not the IDE extensions. Plugins carry no skills: Cline reads SKILL.md from .cline/skills/, .clinerules/skills/, .claude/skills/ and ~/.cline/skills/, not a root skills/. Catalog: cline/marketplace (by PR).

Amp (ampcode.com/docs/customize/plugins)

  • <name>/index.ts exporting default function (amp: PluginAPI); a plugin's skills only through amp.registerSkill({path}). Outside plugins Amp finds skills in .agents/skills, .claude/skills and its config folders, and amp skill add <owner>/<repo> installs a repo's skills.

npx skills (vercel-labs/skills)

  • Finds a root SKILL.md, then skills/ (and .curated, .experimental, .system) up to 3 levels, then about 50 agent skill folders; also reads .claude-plugin/plugin.json and marketplace.json. Frontmatter (Agent Skills spec): name (= folder, 1-64), description (1-1024), optional license, compatibility, metadata, allowed-tools.