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:
@@ -50,8 +50,8 @@ test('install-shared.cjs exports the canonical buildParityManifest + exclusion c
|
||||
'VOLATILE_FILES must be a Set'
|
||||
);
|
||||
assert.ok(
|
||||
installShared.VOLATILE_FILES.has('gsd-file-manifest.json'),
|
||||
"VOLATILE_FILES must keep 'gsd-file-manifest.json' excluded (#2872 acceptance " +
|
||||
installShared.VOLATILE_FILES.has('msd-file-manifest.json'),
|
||||
"VOLATILE_FILES must keep 'msd-file-manifest.json' excluded (#2872 acceptance " +
|
||||
'criterion: the manifest gained manifestVersion/runtime/scope, but its `timestamp` ' +
|
||||
'field is unchanged and still varies per install — if this ever stops being true, ' +
|
||||
'the golden fixtures start hashing a per-install timestamp)'
|
||||
@@ -69,8 +69,8 @@ test('install-shared.cjs exports the canonical buildParityManifest + exclusion c
|
||||
'EXCLUDED_PREFIXES must be an array'
|
||||
);
|
||||
assert.ok(
|
||||
installShared.EXCLUDED_PREFIXES.includes('gsd-core/bin/lib/'),
|
||||
"EXCLUDED_PREFIXES must include 'gsd-core/bin/lib/' (compiled runtime artifacts, build-environment-dependent)"
|
||||
installShared.EXCLUDED_PREFIXES.includes('msd-core/bin/lib/'),
|
||||
"EXCLUDED_PREFIXES must include 'msd-core/bin/lib/' (compiled runtime artifacts, build-environment-dependent)"
|
||||
);
|
||||
});
|
||||
|
||||
@@ -126,16 +126,16 @@ for (const consumer of CONSUMERS) {
|
||||
// byte-identical agent output for every descriptor-driven runtime, run against
|
||||
// the SAME configDir so pathPrefix/attribution/converter outputs must match.
|
||||
|
||||
process.env.GSD_TEST_MODE = '1';
|
||||
process.env.MSD_TEST_MODE = '1';
|
||||
|
||||
const { installRuntimeArtifacts } = require('../gsd-core/bin/lib/install-engine.cjs');
|
||||
const { applySurface } = require('../gsd-core/bin/lib/surface.cjs');
|
||||
const { loadSkillsManifest, resolveProfile } = require('../gsd-core/bin/lib/install-profiles.cjs');
|
||||
const { resolveRuntimeArtifactLayout } = require('../gsd-core/bin/lib/runtime-artifact-layout.cjs');
|
||||
const { installRuntimeArtifacts } = require('../msd-core/bin/lib/install-engine.cjs');
|
||||
const { applySurface } = require('../msd-core/bin/lib/surface.cjs');
|
||||
const { loadSkillsManifest, resolveProfile } = require('../msd-core/bin/lib/install-profiles.cjs');
|
||||
const { resolveRuntimeArtifactLayout } = require('../msd-core/bin/lib/runtime-artifact-layout.cjs');
|
||||
const { cleanup, sandboxHome } = require('./helpers.cjs');
|
||||
const { runMinimalInstall } = require('./helpers/install-shared.cjs');
|
||||
|
||||
const COMMANDS_GSD = path.join(ROOT, 'commands', 'gsd');
|
||||
const COMMANDS_MSD = path.join(ROOT, 'commands', 'msd');
|
||||
|
||||
// The 7 descriptor-driven agent runtimes (cline deferred per code comment:
|
||||
// rules-only local branch + local/global complication).
|
||||
@@ -153,7 +153,7 @@ function snapshotAgents(agentsDir) {
|
||||
const snap = new Map();
|
||||
if (!fs.existsSync(agentsDir)) return snap;
|
||||
for (const name of fs.readdirSync(agentsDir)) {
|
||||
if (!name.startsWith('gsd-')) continue;
|
||||
if (!name.startsWith('msd-')) continue;
|
||||
if (!name.endsWith('.md') && !name.endsWith('.agent.md')) continue;
|
||||
snap.set(name, fs.readFileSync(path.join(agentsDir, name), 'utf8'));
|
||||
}
|
||||
@@ -161,7 +161,7 @@ function snapshotAgents(agentsDir) {
|
||||
}
|
||||
|
||||
// Shared manifest + profile so both paths see the same source agents.
|
||||
const parity1575Manifest = loadSkillsManifest(COMMANDS_GSD);
|
||||
const parity1575Manifest = loadSkillsManifest(COMMANDS_MSD);
|
||||
const parity1575Profile = resolveProfile({ modes: ['full'], manifest: parity1575Manifest });
|
||||
// Same attribution resolver for both paths (undefined → no Co-Authored-By mutation).
|
||||
const resolveAttribution1575 = () => undefined;
|
||||
@@ -190,7 +190,7 @@ describe('#1575 — golden-parity: surface path matches install path for descrip
|
||||
const parityAgentsKind = parityLayout.kinds.find((k) => k.kind === 'agents');
|
||||
const agentsDir = path.join(parityAgentsKind.home ?? configDir, parityAgentsKind.destSubpath);
|
||||
const installSnap = snapshotAgents(agentsDir);
|
||||
assert.ok(installSnap.size > 0, `${runtime}: install must produce at least one gsd-* agent`);
|
||||
assert.ok(installSnap.size > 0, `${runtime}: install must produce at least one msd-* agent`);
|
||||
|
||||
// Step 3: surface path re-materializes into the SAME configDir
|
||||
const layout = resolveRuntimeArtifactLayout(runtime, configDir, 'global');
|
||||
@@ -248,14 +248,14 @@ describe('#1575 — golden-parity: surface path matches install path for descrip
|
||||
});
|
||||
|
||||
test('copilot: agents installed as .agent.md (filename rename parity)', (t) => {
|
||||
const configDir = fs.mkdtempSync(path.join(os.tmpdir(), 'gsd-1575-copilot-rename-'));
|
||||
const configDir = fs.mkdtempSync(path.join(os.tmpdir(), 'msd-1575-copilot-rename-'));
|
||||
t.after(() => { try { cleanup(configDir); } catch { /* best-effort */ } });
|
||||
|
||||
installRuntimeArtifacts('copilot', configDir, 'global', parity1575Profile, resolveAttribution1575);
|
||||
|
||||
const agentsDir = path.join(configDir, 'agents');
|
||||
assert.ok(fs.existsSync(agentsDir), 'copilot agents dir must exist');
|
||||
const agentFiles = fs.readdirSync(agentsDir).filter((f) => f.startsWith('gsd-'));
|
||||
const agentFiles = fs.readdirSync(agentsDir).filter((f) => f.startsWith('msd-'));
|
||||
assert.ok(agentFiles.length > 0, 'copilot must have installed agents');
|
||||
assert.ok(
|
||||
agentFiles.every((f) => f.endsWith('.agent.md')),
|
||||
@@ -265,7 +265,7 @@ describe('#1575 — golden-parity: surface path matches install path for descrip
|
||||
});
|
||||
|
||||
describe('#1575 — surface path: no prune data-loss over pre-existing legacy agents', () => {
|
||||
test('pre-existing gsd-* agents not in staged set are pruned; user agents preserved', (t) => {
|
||||
test('pre-existing msd-* agents not in staged set are pruned; user agents preserved', (t) => {
|
||||
const installed = runMinimalInstall({ runtime: 'copilot', scope: 'global' });
|
||||
const { configDir, root } = installed;
|
||||
t.after(() => { try { cleanup(root); } catch { /* best-effort */ } });
|
||||
@@ -273,14 +273,14 @@ describe('#1575 — surface path: no prune data-loss over pre-existing legacy ag
|
||||
// Seed a pre-existing legacy .agent.md (simulating a prior install)
|
||||
const agentsDir = path.join(configDir, 'agents');
|
||||
fs.mkdirSync(agentsDir, { recursive: true });
|
||||
fs.writeFileSync(path.join(agentsDir, 'gsd-old-defunct.agent.md'), '# Old\n');
|
||||
fs.writeFileSync(path.join(agentsDir, 'msd-old-defunct.agent.md'), '# Old\n');
|
||||
fs.writeFileSync(path.join(agentsDir, 'user-custom.md'), '# User\n');
|
||||
|
||||
// Install (should prune stale gsd-*, preserve user agents)
|
||||
// Install (should prune stale msd-*, preserve user agents)
|
||||
installRuntimeArtifacts('copilot', configDir, 'global', parity1575Profile, resolveAttribution1575);
|
||||
|
||||
const afterInstall = fs.readdirSync(agentsDir);
|
||||
assert.ok(!afterInstall.includes('gsd-old-defunct.agent.md'), 'stale gsd-* agent must be pruned');
|
||||
assert.ok(!afterInstall.includes('msd-old-defunct.agent.md'), 'stale msd-* agent must be pruned');
|
||||
assert.ok(afterInstall.includes('user-custom.md'), 'user agent must be preserved');
|
||||
|
||||
// Now surface over the install — must converge to the same state
|
||||
@@ -289,8 +289,8 @@ describe('#1575 — surface path: no prune data-loss over pre-existing legacy ag
|
||||
|
||||
const afterSurface = fs.readdirSync(agentsDir);
|
||||
// Same set of agent files as after install
|
||||
const installAgents = afterInstall.filter((f) => f.startsWith('gsd-')).sort();
|
||||
const surfaceAgents = afterSurface.filter((f) => f.startsWith('gsd-')).sort();
|
||||
const installAgents = afterInstall.filter((f) => f.startsWith('msd-')).sort();
|
||||
const surfaceAgents = afterSurface.filter((f) => f.startsWith('msd-')).sort();
|
||||
assert.deepEqual(surfaceAgents, installAgents, 'surface must converge to same agent set as install');
|
||||
assert.ok(afterSurface.includes('user-custom.md'), 'user agent still preserved after surface');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user