feat: add ACP registry metadata for Zed

This commit is contained in:
mr-r0b0t 2026-05-14 14:43:27 -05:00 committed by Teknium
parent e8b9f5ff9a
commit 4c94396206
17 changed files with 683 additions and 75 deletions

View file

@ -0,0 +1,23 @@
'use strict';
const test = require('node:test');
const assert = require('node:assert/strict');
const { buildCommand, HERMES_SPEC } = require('../bin/hermes-agent-acp.js');
test('uses uvx when available and forwards args', () => {
const command = buildCommand(['--version'], (name) => name === 'uvx');
assert.equal(command.command, 'uvx');
assert.deepEqual(command.args, ['--from', HERMES_SPEC, 'hermes-acp', '--version']);
});
test('falls back to uv tool run and forwards setup args', () => {
const command = buildCommand(['--setup'], (name) => name === 'uv');
assert.equal(command.command, 'uv');
assert.deepEqual(command.args, ['tool', 'run', '--from', HERMES_SPEC, 'hermes-acp', '--setup']);
});
test('returns null when neither uvx nor uv is available', () => {
assert.equal(buildCommand([], () => false), null);
});