refactor: hard-fork GSD -> MSD (Make Software Done)
Mechanical rename produced by scripts/msd-rename.cjs: gsd/Gsd/GSD -> msd/Msd/MSD across contents and paths, upstream package/repo coordinates -> @golem15/msd-core and golem15com/msd-core. Deep links into upstream history, sibling upstream packages, the GSD-2 import feature, CHANGELOG.md and .changeset/ are kept as-is. Hand edits on top: MSD block-letter banner and logos, LICENSE copyright line, package/plugin identity, regenerated lockfile, install-tree fixtures, derived registries and benchmark baseline; migration checksum baseline re-locked (MSD keeps its own install state, so no install had applied the old sums); sort-order and regex-escaped expectations in tests adjusted.
This commit is contained in:
36
tests/fixtures/pi-host-plugin.cjs
vendored
36
tests/fixtures/pi-host-plugin.cjs
vendored
@@ -1,12 +1,12 @@
|
||||
'use strict';
|
||||
|
||||
/**
|
||||
* Reference pi host-plugin for GSD (ADR-1239 Phase D / #1682 Slice 3).
|
||||
* Reference pi host-plugin for MSD (ADR-1239 Phase D / #1682 Slice 3).
|
||||
*
|
||||
* pi (pi.dev) is a Programmatic-CLI host whose TS extensions implement the
|
||||
* ExtensionAPI (`@earendil-works/pi-coding-agent`): registerTool /
|
||||
* registerCommand / registerShortcut / registerFlag / pi.on(event, …). This
|
||||
* reference plugin binds GSD's command + tool + event surface to pi via the
|
||||
* reference plugin binds MSD's command + tool + event surface to pi via the
|
||||
* IMPERATIVE adapter path — the programmatic-cli peer of the OpenCode worked
|
||||
* binding.
|
||||
*
|
||||
@@ -16,42 +16,42 @@
|
||||
*
|
||||
* #2102 Stage 2: registerCommand takes `handler(args, ctx)` (args is the raw
|
||||
* string after the command) — NOT `execute(ctx)`, which the original #1682
|
||||
* cut used. gsd_invoke's `execute` takes pi's real 5-arg tool-execute
|
||||
* signature `(toolCallId, params, signal, onUpdate, ctx)`. See pi/gsd.cjs for
|
||||
* cut used. msd_invoke's `execute` takes pi's real 5-arg tool-execute
|
||||
* signature `(toolCallId, params, signal, onUpdate, ctx)`. See pi/msd.cjs for
|
||||
* the full production binding this reference fixture mirrors.
|
||||
*
|
||||
* NOTE: this is the reference binding that proves the ExtensionAPI imperative
|
||||
* adapter (#1682 AC), kept as a mock-friendly fixture independent of the real
|
||||
* `pi/gsd.cjs` extension. Full `--pi` installable-runtime integration
|
||||
* `pi/msd.cjs` extension. Full `--pi` installable-runtime integration
|
||||
* (descriptor + installer wiring + golden parity 16→17) shipped in #2102
|
||||
* Stage 1 — see capabilities/pi/capability.json and
|
||||
* tests/fixtures/golden-install-parity/pi.json.
|
||||
*
|
||||
* @param {object} pi pi ExtensionAPI (registerTool/registerCommand/on/…)
|
||||
*/
|
||||
module.exports = function gsdPiPlugin(pi) {
|
||||
module.exports = function msdPiPlugin(pi) {
|
||||
if (!pi || typeof pi !== 'object') {
|
||||
throw new TypeError('gsdPiPlugin: pi ExtensionAPI is required');
|
||||
throw new TypeError('msdPiPlugin: pi ExtensionAPI is required');
|
||||
}
|
||||
|
||||
// Command surface: `/gsd` invokes the GSD command-routing hub via the
|
||||
// Command surface: `/msd` invokes the MSD command-routing hub via the
|
||||
// imperative adapter (createImperativeAdapter({runtime:'pi'}) + dispatch).
|
||||
pi.registerCommand('gsd', {
|
||||
description: 'Invoke a GSD command via the embedded engine (imperative adapter).',
|
||||
pi.registerCommand('msd', {
|
||||
description: 'Invoke a MSD command via the embedded engine (imperative adapter).',
|
||||
handler: async function (args, ctx) {
|
||||
void args;
|
||||
void ctx;
|
||||
// Engine dispatch is wired by the host at load (createImperativeAdapter).
|
||||
// Kept declarative in the reference; the real binding (pi/gsd.cjs)
|
||||
// dispatches through gsd-tools.cjs via dispatchGsdCommand.
|
||||
// Kept declarative in the reference; the real binding (pi/msd.cjs)
|
||||
// dispatches through msd-tools.cjs via dispatchMsdCommand.
|
||||
},
|
||||
});
|
||||
|
||||
// Tool surface: a `gsd_invoke` tool mirroring the companion-MCP tool surface
|
||||
// (interface point 1) so the model can call GSD commands programmatically.
|
||||
// Tool surface: a `msd_invoke` tool mirroring the companion-MCP tool surface
|
||||
// (interface point 1) so the model can call MSD commands programmatically.
|
||||
pi.registerTool({
|
||||
name: 'gsd_invoke',
|
||||
description: 'Invoke a GSD command family/subcommand through the engine.',
|
||||
name: 'msd_invoke',
|
||||
description: 'Invoke a MSD command family/subcommand through the engine.',
|
||||
execute: async function (toolCallId, params, signal, onUpdate, ctx) {
|
||||
void toolCallId;
|
||||
void params;
|
||||
@@ -63,8 +63,8 @@ module.exports = function gsdPiPlugin(pi) {
|
||||
});
|
||||
|
||||
// Event surface: observe tool calls — the pi subset hook surface (peer of the
|
||||
// OpenCode opencode-subset). Attachment point for the GSD hook bridge.
|
||||
// OpenCode opencode-subset). Attachment point for the MSD hook bridge.
|
||||
pi.on('tool_call', async function /* event */ () {
|
||||
/* GSD hook bridge attachment point (PreToolUse/PostToolUse mapping). */
|
||||
/* MSD hook bridge attachment point (PreToolUse/PostToolUse mapping). */
|
||||
});
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user