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

@@ -47,15 +47,15 @@ function expandHome(p: string | undefined | null, home: string): string {
return p.startsWith('~/') ? path.join(home, p.slice(2)) : p;
}
function versionFile(dir: string): string { return path.join(dir, 'gsd-core', 'VERSION'); }
function markerFile(dir: string): string { return path.join(dir, 'gsd-core', 'workflows', 'update.md'); }
function versionFile(dir: string): string { return path.join(dir, 'msd-core', 'VERSION'); }
function markerFile(dir: string): string { return path.join(dir, 'msd-core', 'workflows', 'update.md'); }
export interface FsAdapter {
exists(p: string): boolean;
readFile(p: string): string | null;
}
// Detection: a dir "has GSD" if it carries a VERSION file or the update.md
// Detection: a dir "has MSD" if it carries a VERSION file or the update.md
// workflow marker.
function hasInstall(fs: FsAdapter, dir: string): boolean {
return fs.exists(versionFile(dir)) || fs.exists(markerFile(dir));
@@ -164,11 +164,11 @@ export interface UpdateContext {
installedVersion: string;
scope: 'LOCAL' | 'GLOBAL' | 'UNKNOWN';
runtime: string;
gsdDir: string;
msdDir: string;
}
/**
* Pure resolver. Returns { installedVersion, scope, runtime, gsdDir }.
* Pure resolver. Returns { installedVersion, scope, runtime, msdDir }.
*/
export function resolveUpdateContext({
home,
@@ -199,7 +199,7 @@ export function resolveUpdateContext({
installedVersion: trustedVersionAt(fs, preferredConfigDir) ?? '0.0.0',
scope,
runtime: preferred,
gsdDir: preferredConfigDir,
msdDir: preferredConfigDir,
};
}
@@ -220,22 +220,22 @@ export function resolveUpdateContext({
const isLocal = !!localValid && (!globalDir || localDir !== globalDir);
if (isLocal) {
return { installedVersion: localValid, scope: 'LOCAL', runtime: localRuntime, gsdDir: localDir };
return { installedVersion: localValid, scope: 'LOCAL', runtime: localRuntime, msdDir: localDir };
}
const globalValid = trustedVersionAt(fs, globalDir);
if (globalValid) {
return { installedVersion: globalValid, scope: 'GLOBAL', runtime: globalRuntime, gsdDir: globalDir };
return { installedVersion: globalValid, scope: 'GLOBAL', runtime: globalRuntime, msdDir: globalDir };
}
// A runtime dir was detected (VERSION or marker present) but is not a
// complete, valid install: keep scope/runtime/dir and report 0.0.0 so the
// caller re-installs.
if (localRuntime && (!globalDir || localDir !== globalDir)) {
return { installedVersion: '0.0.0', scope: 'LOCAL', runtime: localRuntime, gsdDir: localDir };
return { installedVersion: '0.0.0', scope: 'LOCAL', runtime: localRuntime, msdDir: localDir };
}
if (globalRuntime) {
return { installedVersion: '0.0.0', scope: 'GLOBAL', runtime: globalRuntime, gsdDir: globalDir };
return { installedVersion: '0.0.0', scope: 'GLOBAL', runtime: globalRuntime, msdDir: globalDir };
}
return { installedVersion: '0.0.0', scope: 'UNKNOWN', runtime: '', gsdDir: '' };
return { installedVersion: '0.0.0', scope: 'UNKNOWN', runtime: '', msdDir: '' };
}
export interface LoadUpdateContextOpts {