@chrisdudek/yg 5.2.2 → 5.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/bin.js +11 -8
  2. package/package.json +1 -1
package/dist/bin.js CHANGED
@@ -3621,13 +3621,12 @@ async function writeLock(yggRoot, lock, opts = {}) {
3621
3621
  }
3622
3622
  const { det, nondet } = partitionVerdicts(lock.verdicts, detIds);
3623
3623
  if (scope === "deterministic") {
3624
- const content20 = serializeLock({ version: lock.version, verdicts: det, nodes: {} });
3625
- await writeFileIfChanged(detLockPath(yggRoot), content20);
3624
+ await writeOrRemoveSplitFile(detLockPath(yggRoot), lock.version, det, {});
3626
3625
  return;
3627
3626
  }
3628
- await writeFileIfChanged(nondetLockPath(yggRoot), serializeLock({ version: lock.version, verdicts: nondet, nodes: {} }));
3627
+ await writeOrRemoveSplitFile(nondetLockPath(yggRoot), lock.version, nondet, {});
3629
3628
  await writeOrRemoveSplitFile(logsLockPath(yggRoot), lock.version, {}, lock.nodes);
3630
- await writeFileIfChanged(detLockPath(yggRoot), serializeLock({ version: lock.version, verdicts: det, nodes: {} }));
3629
+ await writeOrRemoveSplitFile(detLockPath(yggRoot), lock.version, det, {});
3631
3630
  }
3632
3631
 
3633
3632
  // src/cli/preamble.ts
@@ -19534,10 +19533,14 @@ pairs on that node \u2014 a legitimate vacuous pass, no verdict, no entry.
19534
19533
  \`yg knowledge read log-management\`) and the append-only log integrity baseline.
19535
19534
  The source fingerprint is the log gate's drift basis, so it is recorded ONLY for
19536
19535
  \`log_required\` nodes \u2014 a non-log_required node gets a \`nodes\` entry only when it
19537
- owns a \`log.md\` (then holding just the \`log\` baseline, no \`source\`). When the
19538
- \`nodes\` section is empty (no log_required node, no \`log.md\`), \`yg-lock.logs.json\`
19539
- is not written at all \u2014 an empty committed husk is removed, and readLock treats
19540
- an absent file as empty state.
19536
+ owns a \`log.md\` (then holding just the \`log\` baseline, no \`source\`).
19537
+ - Empty section \u21D2 no file. Each of the three split files is written ONLY when its
19538
+ section is non-empty; when empty it is not written at all (an existing empty husk
19539
+ is removed). So a repo with no LLM aspects has no \`yg-lock.nondeterministic.json\`,
19540
+ one with no \`log_required\` node and no \`log.md\` has no \`yg-lock.logs.json\`, and
19541
+ one with no deterministic aspects has no \`.yg-lock.deterministic.json\`. readLock
19542
+ treats an absent file as empty state, so this is transparent to every reader \u2014 a
19543
+ repo only carries the lock files it actually needs.
19541
19544
  - The built-in relation-conformance check is NOT stored in the lock \u2014 it is
19542
19545
  recomputed live on every \`yg check\`. The lock holds only aspect \`verdicts\`
19543
19546
  and per-node \`nodes\` facts; there is no relation section. See "Relation
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chrisdudek/yg",
3
- "version": "5.2.2",
3
+ "version": "5.2.3",
4
4
  "description": "Architecture rules your AI coding agent can't ignore. It gets the rules for a file before it edits, and every change is checked — by a free local script or an LLM reviewer — before it moves on. Works with Claude Code, Cursor, Copilot, Codex, Cline.",
5
5
  "type": "module",
6
6
  "bin": {