diff --git a/bin/check.js b/bin/check.js index d6db136..ecb7c5b 100644 --- a/bin/check.js +++ b/bin/check.js @@ -402,8 +402,10 @@ if (apMcp.$schema !== AP_MCP_SCHEMA) { } } const ingest = apServers['fdeops-ingest'] - const target = ingest && (ingest.args || []).join(' ').replace('${PLUGIN_ROOT}/', '') + const rootArg = ingest && (ingest.args || []).find(a => String(a).startsWith('${PLUGIN_ROOT}/')) + const target = rootArg && String(rootArg).replace('${PLUGIN_ROOT}/', '') if (!ingest) fail('mcp.json must declare the fdeops-ingest stdio server') + else if (!target) fail('mcp.json fdeops-ingest must pass a ${PLUGIN_ROOT}-relative server path in args') else if (!fs.existsSync(path.join(root, target))) fail(`mcp.json fdeops-ingest points at missing ${target}`) else ok('agent plugins mcp config') }