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:
@@ -13,10 +13,10 @@
|
||||
* `buildPlanningSnapshot(cwd)` is the sole export consumers reach for;
|
||||
* `worstScope` is exported alongside it for direct unit coverage.
|
||||
*
|
||||
* Design: .gsd/phase/refactor-3308-planning-snapshot-parsed-projection/40-design.md
|
||||
* Design: .msd/phase/refactor-3308-planning-snapshot-parsed-projection/40-design.md
|
||||
*
|
||||
* ADR-457 build-at-publish: source in src/planning-snapshot.cts, compiled to
|
||||
* gsd-core/bin/lib/planning-snapshot.cjs (gitignored).
|
||||
* msd-core/bin/lib/planning-snapshot.cjs (gitignored).
|
||||
*/
|
||||
|
||||
import fs from 'node:fs';
|
||||
@@ -270,7 +270,7 @@ interface PlanningSnapshot {
|
||||
// on every repo that has not opted in, which is the value each widened read
|
||||
// compiles its BASE (byte-identical) grammar from.
|
||||
phaseIdConvention: string | null;
|
||||
// Tokens borne ONLY by sentinel-bracket ROADMAP headings (`### [GSD.999] 07:`
|
||||
// Tokens borne ONLY by sentinel-bracket ROADMAP headings (`### [MSD.999] 07:`
|
||||
// yields token `07`). Produced by the same `buildRoadmapPhaseVariants` call
|
||||
// that produces `roadmapDeclaredPhases`, so the two can never disagree about
|
||||
// which headings they saw. EMPTY unless the bracket convention is active.
|
||||
@@ -278,7 +278,7 @@ interface PlanningSnapshot {
|
||||
// Its own field because bracket sentinel-ness lives in the MILESTONE, not the
|
||||
// token: a bare-token test (`isSentinelPhaseId`, #3225) cannot see it once the
|
||||
// heading is reduced to `07`. The two guards are DISJOINT — #3225 reads legacy
|
||||
// `### Phase 999:`, this reads `### [GSD.999] 07:` — and `checkW006` needs both.
|
||||
// `### Phase 999:`, this reads `### [MSD.999] 07:` — and `checkW006` needs both.
|
||||
roadmapSentinelPhaseTokens: { value: string[]; scope: Scope };
|
||||
// Bracket-coherence findings (`checkBracketCoherence`, `validate.cjs`) — the
|
||||
// bracket half of W021. Computed ONLY under the bracket convention; a legacy
|
||||
@@ -362,7 +362,7 @@ interface StateFields {
|
||||
* that diagnostic; it still attempts a body-only field read on whatever
|
||||
* `stripFrontmatter` leaves behind.
|
||||
* - `currentPhaseLabel`/`stateStatus` both live under `## Current Position`
|
||||
* (`gsd-core/templates/state.md`) and both use `stateFieldValue`
|
||||
* (`msd-core/templates/state.md`) and both use `stateFieldValue`
|
||||
* (`state-document.cts:296`) the exact way `smart-entry.cts:448`/
|
||||
* `state.cts:1561,3273` already call it for `'status'`/`'Status'` — so a
|
||||
* missing `## Current Position` section degrades BOTH to `TRUNCATED` with
|
||||
@@ -404,7 +404,7 @@ function buildStateFields(statePath: string): StateFields {
|
||||
// `resolveStatePhase` (its three-source ladder at `state.cts:1494-1516`),
|
||||
// including the frontmatter step that ladder leads with:
|
||||
// 1. frontmatter `current_phase` scalar — the machine-readable key
|
||||
// `gsd-tools state update` / `state begin-phase` persist via
|
||||
// `msd-tools state update` / `state begin-phase` persist via
|
||||
// `syncStateFrontmatter` (`state.cts:2023`), so it takes PRIORITY over
|
||||
// any body field (#3280: a body-only ladder left W011 structurally
|
||||
// blind to the one format the product itself writes — a stale body
|
||||
@@ -443,12 +443,12 @@ function buildStateFields(statePath: string): StateFields {
|
||||
// 1. Strip fenced code blocks, then inline code spans (the #2365
|
||||
// composition order, via the canonical markdown-sectionizer seam) —
|
||||
// a token inside backticks is a QUOTED LITERAL (a ledger row quoting
|
||||
// `` `/gsd-execute-phase 5` `` or `` `- [ ] **Phase 40:` `` from a
|
||||
// `` `/msd-execute-phase 5` `` or `` `- [ ] **Phase 40:` `` from a
|
||||
// sibling roadmap), not a reference. Pinned tradeoff: a GENUINE
|
||||
// reference written in backticks stops counting too — a quoted
|
||||
// literal and a reference are indistinguishable inside a code span.
|
||||
// 2. Left word boundary `(?<![-\w])` — the `-phase 5` tail of GSD's own
|
||||
// command names (`/gsd-execute-phase 5`, bare or in prose) is a
|
||||
// 2. Left word boundary `(?<![-\w])` — the `-phase 5` tail of MSD's own
|
||||
// command names (`/msd-execute-phase 5`, bare or in prose) is a
|
||||
// command mention, not a reference, and word-suffixed carriers
|
||||
// (`myphase 5`) never were references. `Phase 5` at line start,
|
||||
// `**Phase 5:**`, `(Phase 5)`, `[Phase 5]`, and `### Phase 5:` all
|
||||
@@ -818,7 +818,7 @@ function buildRoadmapPhaseCheckboxesField(
|
||||
// `buildNotStartedPhaseVariants` (`validate.cts`) selects it for the same
|
||||
// ROADMAP checklist shape — this field is what W006's not-started exclusion
|
||||
// now reads instead of that helper, so the two must recognize the same
|
||||
// checklist lines or a bracket repo's `- [ ] **[GSD.02] 05: Name**` entries
|
||||
// checklist lines or a bracket repo's `- [ ] **[MSD.02] 05: Name**` entries
|
||||
// vanish from the exclusion set and every unstarted bracket phase gains a
|
||||
// W006. NON-capturing (`capturing` defaults false), so the phase token stays
|
||||
// group 2 and the legacy repo compiles a byte-identical source.
|
||||
@@ -1137,7 +1137,7 @@ function buildCurrentMilestoneRoadmapPhaseIdsField(
|
||||
// ("STATE says milestone complete but ROADMAP lists an unstarted phase")
|
||||
// fire on every bracket repo that keeps an icebox. Filtered here rather
|
||||
// than in `RULE_W026` because the bracket id is only visible at the match:
|
||||
// the emitted token is `07`, and sentinel-ness lives in the `[GSD.999]`
|
||||
// the emitted token is `07`, and sentinel-ness lives in the `[MSD.999]`
|
||||
// milestone this scan just discarded. This field's only consumer is W026
|
||||
// (see its own doc comment above).
|
||||
if (bracketId && isSentinelPhaseId(`${bracketId}-${phaseNum}`, 'bracket')) continue;
|
||||
|
||||
Reference in New Issue
Block a user