diff --git a/marketplace.json b/marketplace.json index 8bc7efb..c4a3b30 100644 --- a/marketplace.json +++ b/marketplace.json @@ -1,5 +1,4 @@ { - "$schema": "https://agent-plugins.org/schemas/1.0.0/marketplace.schema.json", "name": "redsen", "owner": { "name": "Redsen", diff --git a/plugin.json b/plugin.json index 6189662..abb4423 100644 --- a/plugin.json +++ b/plugin.json @@ -1,5 +1,4 @@ { - "$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json", "name": "redsen-lean-harness", "description": "Imperative, token-lean, self-documenting agent harness. Spec-driven pipeline with a Ralph implement/verify loop, dynamic parallel worktree lanes, file-based memory, tree-sitter repo index, and zero-server telemetry. Works in GitHub Copilot CLI and VS Code Copilot.", "version": "0.1.0", diff --git a/scripts/validate.mjs b/scripts/validate.mjs index 7948366..a6f4353 100644 --- a/scripts/validate.mjs +++ b/scripts/validate.mjs @@ -110,14 +110,27 @@ function validatePlugin() { if (manifest.version && !/^\d+\.\d+\.\d+(-[\w.]+)?(\+[\w.]+)?$/.test(manifest.version)) { error(file, `version "${manifest.version}" is not semver`); } - if (!manifest.$schema?.includes('agent-plugins.org')) { - warn(file, 'missing the agent-plugins.org $schema reference'); + // NOTE: do NOT set $schema to the agent-plugins.org Open Plugin Spec URL. + // Verified against a real Copilot CLI 1.0.83 install: declaring $schema + // opts the manifest into Open Plugin Spec mode, which silently drops the + // plugin's agents/skills (0 loaded) instead of reading the flat fields + // below. Component paths must be flat top-level fields, not nested under + // an "extensions" object (that key means something unrelated in the + // non-spec schema and is also silently ignored when present as an object). + if (manifest.$schema) { + error(file, '"$schema" must not be set \u2014 it silently disables agent/skill loading in Copilot CLI'); + } + if (manifest.extensions) { + error(file, '"extensions" is not a valid location for agents/skills \u2014 use top-level "agents"/"skills" fields'); } - const ext = manifest.extensions?.['com.github.copilot'] ?? {}; - for (const [key, target] of Object.entries(ext)) { - const abs = path.resolve(ROOT, target); - if (!fs.existsSync(abs)) error(file, `extensions.com.github.copilot.${key} points at missing path "${target}"`); + for (const key of ['agents', 'skills']) { + const target = manifest[key]; + if (!target) continue; + for (const rel of Array.isArray(target) ? target : [target]) { + const abs = path.resolve(ROOT, rel); + if (!fs.existsSync(abs)) error(file, `${key} points at missing path "${rel}"`); + } } return manifest; }