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

@@ -29,7 +29,7 @@ const assert = require('node:assert/strict');
const fs = require('fs');
const path = require('path');
const { scanForInjection } = require('../gsd-core/bin/lib/security.cjs');
const { scanForInjection } = require('../msd-core/bin/lib/security.cjs');
const { runHook } = require('./helpers/process-seam.cjs');
const { createTempDir, cleanup } = require('./helpers.cjs');
const { QUICK_SPAWN_TIMEOUT_MS } = require('./helpers/timeouts.cjs');
@@ -48,7 +48,7 @@ const SCAN_SCRIPT = path.join(PROJECT_ROOT, 'scripts', 'prompt-injection-scan.sh
* shell script's PATTERNS array.
*/
function scanContent(t, content) {
const dir = createTempDir('gsd-3175-pi-scan-');
const dir = createTempDir('msd-3175-pi-scan-');
t.after(() => cleanup(dir));
const file = path.join(dir, 'fixture.txt');
fs.writeFileSync(file, `${content}\n`);
@@ -60,8 +60,8 @@ function scanContent(t, content) {
const SCAN_DIRS = [
'agents',
'commands',
'gsd-core/workflows',
'gsd-core/bin/lib',
'msd-core/workflows',
'msd-core/bin/lib',
'hooks',
];
@@ -71,13 +71,13 @@ const SCAN_EXTS = new Set(['.md', '.cjs', '.js', '.json']);
// Files that legitimately reference injection patterns (e.g., security docs, this test)
// or exceed the 50K size threshold due to legitimate workflow complexity
const ALLOWLIST = new Set([
'gsd-core/bin/lib/security.cjs', // The security module itself
'gsd-core/workflows/discuss-phase.md', // Large workflow (~50K) with power mode + i18n
'gsd-core/workflows/new-project.md', // Large workflow (~50K) — agent install, runtime detect, brownfield map, #3491 worktree gating
'gsd-core/workflows/execute-phase.md', // Large orchestration workflow (~51K) with wave execution + code-review gate
'gsd-core/workflows/plan-phase.md', // Large orchestration workflow (~51K) with TDD mode integration
'hooks/gsd-prompt-guard.js', // The prompt guard hook
'hooks/gsd-read-injection-scanner.js', // The read injection scanner (contains patterns)
'msd-core/bin/lib/security.cjs', // The security module itself
'msd-core/workflows/discuss-phase.md', // Large workflow (~50K) with power mode + i18n
'msd-core/workflows/new-project.md', // Large workflow (~50K) — agent install, runtime detect, brownfield map, #3491 worktree gating
'msd-core/workflows/execute-phase.md', // Large orchestration workflow (~51K) with wave execution + code-review gate
'msd-core/workflows/plan-phase.md', // Large orchestration workflow (~51K) with TDD mode integration
'hooks/msd-prompt-guard.js', // The prompt guard hook
'hooks/msd-read-injection-scanner.js', // The read injection scanner (contains patterns)
'tests/security.test.cjs', // Security tests
'tests/prompt-injection-scan.security.test.cjs', // This file
]);
@@ -88,19 +88,19 @@ const ALLOWLIST = new Set([
// Do NOT add files here that legitimately reference injection patterns (those
// belong in ALLOWLIST). Only add files that are large but otherwise clean.
const SIZE_ONLY_WORKFLOWS = new Set([
'gsd-core/workflows/docs-update.md', // ~51K after fix-loop truncation guard (#571)
'msd-core/workflows/docs-update.md', // ~51K after fix-loop truncation guard (#571)
// ~50.7K after the per-reviewer effort wiring (#2481). This file sat at 49,971
// chars — 29 below the 50K prompt-stuffing threshold — so it was going to trip
// on whatever was added to it next. Size-only: the file is still fully injection
// scanned, exactly like docs-update.md. Splitting it per the progressive-
// disclosure pattern is the real fix and is worth its own change.
'gsd-core/workflows/review.md',
'msd-core/workflows/review.md',
// ~50.2K after the #2711 omit-rule block. This file sat at 49,9xx chars on next —
// under the 50K prompt-stuffing threshold by ~200 — so, exactly like review.md above,
// it was going to trip on whatever was added to it next. Size-only: still fully
// injection scanned. Splitting it per the progressive-disclosure pattern is the real
// fix and is worth its own change.
'gsd-core/workflows/quick.md',
'msd-core/workflows/quick.md',
// ~52K after #3829's disposition ledger. Same shape as the two above: this file sat at 44,466
// chars on next — 89% of the 50,000-char prompt-stuffing threshold — so the feature approved on
// the issue could not land in it without tripping this. The round's committed peak was 59,246
@@ -118,7 +118,7 @@ const SIZE_ONLY_WORKFLOWS = new Set([
// Size-only: still fully injection scanned, exactly like the two above.
// Splitting it per the progressive-disclosure pattern is the real fix and is worth its own change
// — it is already a step file extracted from execute-phase.md for that same reason.
'gsd-core/workflows/execute-phase/steps/code-review-disposition.md',
'msd-core/workflows/execute-phase/steps/code-review-disposition.md',
]);
// ─── Scanner ────────────────────────────────────────────────────────────────
@@ -162,8 +162,8 @@ describe('codebase prompt injection scan', () => {
for (const file of agentFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -195,8 +195,8 @@ describe('codebase prompt injection scan', () => {
for (const file of agentFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -219,8 +219,8 @@ describe('codebase prompt injection scan', () => {
for (const file of workflowFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -251,8 +251,8 @@ describe('codebase prompt injection scan', () => {
for (const file of commandFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -277,8 +277,8 @@ describe('codebase prompt injection scan', () => {
for (const file of hookFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -303,8 +303,8 @@ describe('codebase prompt injection scan', () => {
for (const file of libFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -329,8 +329,8 @@ describe('codebase prompt injection scan', () => {
for (const file of allFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
@@ -361,8 +361,8 @@ describe('codebase prompt injection scan', () => {
for (const file of allFiles) {
// Normalize to POSIX separators so ALLOWLIST.has() works on Windows
// (path.relative returns 'gsd-core\bin\...' on win32; allowlist
// keys are POSIX 'gsd-core/bin/...').
// (path.relative returns 'msd-core\bin\...' on win32; allowlist
// keys are POSIX 'msd-core/bin/...').
const relPath = path.relative(PROJECT_ROOT, file).replace(/\\/g, '/');
if (ALLOWLIST.has(relPath)) continue;
// Allow .md files to use common tags in examples/docs
@@ -478,7 +478,7 @@ Build a JWT-based authentication system with login, logout, and session manageme
// - REGRESSION: a false positive that must scan clean after the fix, or
// - NON-WEAKENING: a real payload that must still be detected.
// The `scanForInjection()` suite above tests a separate pattern set
// (gsd-core/bin/lib/security.cjs) and is unaffected by this fix.
// (msd-core/bin/lib/security.cjs) and is unaffected by this fix.
describe('shell scanner (scripts/prompt-injection-scan.sh) — #3175 left-boundary fix', () => {
test('regression: CONTEXT.md:124 prose no longer false-positives on "act"', (t) => {