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:
Jakub Zych
2026-10-06 01:47:40 +02:00
parent fe069b2a56
commit a9a7a328e6
2763 changed files with 78465 additions and 78434 deletions

View File

@@ -3,7 +3,7 @@
// IS what the runtime loads. Testing text content tests the deployed contract.
// Per CONTRIBUTING.md exception matrix.
process.env.GSD_TEST_MODE = '1';
process.env.MSD_TEST_MODE = '1';
const { test, describe, beforeEach, afterEach } = require('node:test');
const assert = require('node:assert/strict');
@@ -22,14 +22,14 @@ const {
writeManifest,
} = require('../bin/install.js');
const { installRuntimeArtifacts } = require('../gsd-core/bin/lib/install-engine.cjs');
const { getDirName } = require('../gsd-core/bin/lib/runtime-name-policy.cjs');
const { installRuntimeArtifacts } = require('../msd-core/bin/lib/install-engine.cjs');
const { getDirName } = require('../msd-core/bin/lib/runtime-name-policy.cjs');
const { getGlobalConfigDir } = require('../gsd-core/bin/lib/runtime-homes.cjs');
const { getGlobalConfigDir } = require('../msd-core/bin/lib/runtime-homes.cjs');
// ─── Profile resolution for installRuntimeArtifacts tests ────────────────────
const _gsdLibDir = path.join(__dirname, '..', 'gsd-core', 'bin', 'lib');
const { loadSkillsManifest, resolveProfile } = require(path.join(_gsdLibDir, 'install-profiles.cjs'));
const _msdLibDir = path.join(__dirname, '..', 'msd-core', 'bin', 'lib');
const { loadSkillsManifest, resolveProfile } = require(path.join(_msdLibDir, 'install-profiles.cjs'));
const _manifest = loadSkillsManifest();
const resolvedProfileFull = resolveProfile({ modes: [], manifest: _manifest });
@@ -96,15 +96,15 @@ describe('CodeBuddy markdown conversion', () => {
test('converts Claude-specific references to CodeBuddy equivalents', () => {
const input = [
'Claude Code reads CLAUDE.md before using .claude/skills/.',
'Run /gsd:plan-phase with $ARGUMENTS.',
'Run /msd:plan-phase with $ARGUMENTS.',
'Use Bash(command) and Edit(file).',
].join('\n');
const result = convertClaudeToCodebuddyMarkdown(input);
assert.ok(result.includes('CodeBuddy reads CODEBUDDY.md before using .codebuddy/skills/.'), result);
assert.ok(result.includes('/gsd-plan-phase'), result);
assert.ok(result.includes('{{GSD_ARGS}}'), result);
assert.ok(result.includes('/msd-plan-phase'), result);
assert.ok(result.includes('{{MSD_ARGS}}'), result);
// CodeBuddy uses the same tool names as Claude Code — no conversion needed
assert.ok(result.includes('Bash('), result);
assert.ok(result.includes('Edit('), result);
@@ -112,14 +112,14 @@ describe('CodeBuddy markdown conversion', () => {
test('converts commands and agents to CodeBuddy frontmatter', () => {
const command = `---
name: gsd:new-project
name: msd:new-project
description: Initialize a project
---
Use .claude/skills/ and /gsd:help.
Use .claude/skills/ and /msd:help.
`;
const agent = `---
name: gsd-planner
name: msd-planner
description: Planner agent
tools: Read, Write
color: blue
@@ -128,41 +128,41 @@ color: blue
Read CLAUDE.md before acting.
`;
const convertedCommand = convertClaudeCommandToCodebuddySkill(command, 'gsd-new-project');
const convertedCommand = convertClaudeCommandToCodebuddySkill(command, 'msd-new-project');
const convertedAgent = convertClaudeAgentToCodebuddyAgent(agent);
assert.ok(convertedCommand.includes('name: gsd-new-project'), convertedCommand);
assert.ok(convertedCommand.includes('name: msd-new-project'), convertedCommand);
assert.ok(convertedCommand.includes('.codebuddy/skills/'), convertedCommand);
assert.ok(convertedCommand.includes('/gsd-help'), convertedCommand);
assert.ok(convertedCommand.includes('/msd-help'), convertedCommand);
assert.ok(convertedAgent.includes('name: gsd-planner'), convertedAgent);
assert.ok(convertedAgent.includes('name: msd-planner'), convertedAgent);
assert.ok(!convertedAgent.includes('color:'), convertedAgent);
assert.ok(convertedAgent.includes('CODEBUDDY.md'), convertedAgent);
});
});
describe('installRuntimeArtifacts (codebuddy integration)', () => {
// Pivoted from copyCommandsAsCodebuddySkills(srcDir, skillsDir, 'gsd', '$HOME/.codebuddy/', 'codebuddy')
// Pivoted from copyCommandsAsCodebuddySkills(srcDir, skillsDir, 'msd', '$HOME/.codebuddy/', 'codebuddy')
// shim to installRuntimeArtifacts('codebuddy', configDir, 'local', resolvedProfileFull).
// Output layout: <configDir>/skills/gsd-<stem>/SKILL.md (destSubpath='skills', prefix='gsd-').
// Output layout: <configDir>/skills/msd-<stem>/SKILL.md (destSubpath='skills', prefix='msd-').
let configDir;
beforeEach(() => {
configDir = createTempDir('gsd-codebuddy-copy-');
configDir = createTempDir('msd-codebuddy-copy-');
});
afterEach(() => {
cleanup(configDir);
});
test('creates one skill directory per GSD command', () => {
test('creates one skill directory per MSD command', () => {
installRuntimeArtifacts('codebuddy', configDir, 'local', resolvedProfileFull);
const generated = path.join(configDir, 'skills', 'gsd-help', 'SKILL.md');
const generated = path.join(configDir, 'skills', 'msd-help', 'SKILL.md');
assert.ok(fs.existsSync(generated), generated);
const content = fs.readFileSync(generated, 'utf8');
assert.ok(content.includes('name: gsd-help'), content);
assert.ok(content.includes('name: msd-help'), content);
});
});
@@ -171,7 +171,7 @@ describe('CodeBuddy local install/uninstall', () => {
let previousCwd;
beforeEach(() => {
tmpDir = createTempDir('gsd-codebuddy-install-');
tmpDir = createTempDir('msd-codebuddy-install-');
previousCwd = process.cwd();
process.chdir(tmpDir);
});
@@ -181,7 +181,7 @@ describe('CodeBuddy local install/uninstall', () => {
cleanup(tmpDir);
});
test('installs GSD into ./.codebuddy and removes it cleanly', () => {
test('installs MSD into ./.codebuddy and removes it cleanly', () => {
const result = install(false, 'codebuddy');
const targetDir = path.join(tmpDir, '.codebuddy');
@@ -189,17 +189,17 @@ describe('CodeBuddy local install/uninstall', () => {
assert.strictEqual(result.runtime, 'codebuddy');
assert.ok(result.settingsPath, 'should have settingsPath (CodeBuddy supports hooks)');
assert.ok(fs.existsSync(path.join(targetDir, 'skills', 'gsd-help', 'SKILL.md')));
assert.ok(fs.existsSync(path.join(targetDir, 'gsd-core', 'VERSION')));
assert.ok(fs.existsSync(path.join(targetDir, 'skills', 'msd-help', 'SKILL.md')));
assert.ok(fs.existsSync(path.join(targetDir, 'msd-core', 'VERSION')));
assert.ok(fs.existsSync(path.join(targetDir, 'agents')));
const manifest = writeManifest(targetDir, 'codebuddy');
assert.ok(Object.keys(manifest.files).some(file => file.startsWith('skills/gsd-help/')), JSON.stringify(manifest));
assert.ok(Object.keys(manifest.files).some(file => file.startsWith('skills/msd-help/')), JSON.stringify(manifest));
uninstall(false, 'codebuddy');
assert.ok(!fs.existsSync(path.join(targetDir, 'skills', 'gsd-help')), 'CodeBuddy skill directory removed');
assert.ok(!fs.existsSync(path.join(targetDir, 'gsd-core')), 'gsd-core removed');
assert.ok(!fs.existsSync(path.join(targetDir, 'skills', 'msd-help')), 'CodeBuddy skill directory removed');
assert.ok(!fs.existsSync(path.join(targetDir, 'msd-core')), 'msd-core removed');
});
});
@@ -208,7 +208,7 @@ describe('E2E: CodeBuddy uninstall skills cleanup', () => {
let previousCwd;
beforeEach(() => {
tmpDir = createTempDir('gsd-codebuddy-uninstall-');
tmpDir = createTempDir('msd-codebuddy-uninstall-');
previousCwd = process.cwd();
process.chdir(tmpDir);
});
@@ -218,7 +218,7 @@ describe('E2E: CodeBuddy uninstall skills cleanup', () => {
cleanup(tmpDir);
});
test('removes all gsd-* skill directories on --codebuddy --uninstall', () => {
test('removes all msd-* skill directories on --codebuddy --uninstall', () => {
const targetDir = path.join(tmpDir, '.codebuddy');
install(false, 'codebuddy');
@@ -226,20 +226,20 @@ describe('E2E: CodeBuddy uninstall skills cleanup', () => {
assert.ok(fs.existsSync(skillsDir), 'skills dir exists after install');
const installedSkills = fs.readdirSync(skillsDir, { withFileTypes: true })
.filter(e => e.isDirectory() && e.name.startsWith('gsd-'));
assert.ok(installedSkills.length > 0, `found ${installedSkills.length} gsd-* skill dirs before uninstall`);
.filter(e => e.isDirectory() && e.name.startsWith('msd-'));
assert.ok(installedSkills.length > 0, `found ${installedSkills.length} msd-* skill dirs before uninstall`);
uninstall(false, 'codebuddy');
if (fs.existsSync(skillsDir)) {
const remainingGsd = fs.readdirSync(skillsDir, { withFileTypes: true })
.filter(e => e.isDirectory() && e.name.startsWith('gsd-'));
assert.strictEqual(remainingGsd.length, 0,
`Expected 0 gsd-* skill dirs after uninstall, found: ${remainingGsd.map(e => e.name).join(', ')}`);
const remainingMsd = fs.readdirSync(skillsDir, { withFileTypes: true })
.filter(e => e.isDirectory() && e.name.startsWith('msd-'));
assert.strictEqual(remainingMsd.length, 0,
`Expected 0 msd-* skill dirs after uninstall, found: ${remainingMsd.map(e => e.name).join(', ')}`);
}
});
test('preserves non-GSD skill directories during --codebuddy --uninstall', () => {
test('preserves non-MSD skill directories during --codebuddy --uninstall', () => {
const targetDir = path.join(tmpDir, '.codebuddy');
install(false, 'codebuddy');
@@ -252,19 +252,19 @@ describe('E2E: CodeBuddy uninstall skills cleanup', () => {
uninstall(false, 'codebuddy');
assert.ok(fs.existsSync(path.join(customSkillDir, 'SKILL.md')),
'Non-GSD skill directory should be preserved after CodeBuddy uninstall');
'Non-MSD skill directory should be preserved after CodeBuddy uninstall');
});
test('removes engine directory on --codebuddy --uninstall', () => {
const targetDir = path.join(tmpDir, '.codebuddy');
install(false, 'codebuddy');
assert.ok(fs.existsSync(path.join(targetDir, 'gsd-core', 'VERSION')),
assert.ok(fs.existsSync(path.join(targetDir, 'msd-core', 'VERSION')),
'engine exists before uninstall');
uninstall(false, 'codebuddy');
assert.ok(!fs.existsSync(path.join(targetDir, 'gsd-core')),
'gsd-core engine should be removed after CodeBuddy uninstall');
assert.ok(!fs.existsSync(path.join(targetDir, 'msd-core')),
'msd-core engine should be removed after CodeBuddy uninstall');
});
});