Skip to content

Commit a59100d

Browse files
TMHSDigitalclaude
andcommitted
Changelog page from the review ledger; README Recent block generated from it (#91)
- docs/review-ledger.md is a guide page (guide/changelog/), linked from the guide list and every page's footer, so it is in the sitemap - lib/ledger.mjs parses the dated sections; npm run counts writes the README Recent block from the three newest, and validate fails when the block drifts from the ledger - a ledger section for this run; ROADMAP item moved to Done The page lives at guide/changelog/ rather than /changelog/, so it reuses the guide renderer and page checks; no changelog.xml feed. Closes #91 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LpkeXQPaUhxjgqdqnk6BrJ
1 parent c912152 commit a59100d

9 files changed

Lines changed: 83 additions & 4 deletions

File tree

‎README.md‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,10 @@ re-check forty tabs before a release. (Thanks to magictools: many tool entries s
4949
</tr>
5050
</table>
5151

52-
> **Recent:** 2026-10-04, 15 more video, animation and environment sources.
53-
> 2026-09-30, 42 more sources, mostly pipeline, pixel-art and chiptune tools.
54-
> 2026-09-25, starter stacks and a licence freshness page.
52+
> **Recent:** 2026-11-07, audit pass 5 fixes: #246 to #272, then #203, #110, #89, #91.
53+
> 2026-10-22, open issues sweep: #77 to #114.
54+
> 2026-10-13, Unreal Engine sources.
55+
> Every run is in the [changelog](docs/review-ledger.md).
5556
5657
## Contents
5758

‎ROADMAP.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ missing entry, so freshness and accuracy come before volume.
2121

2222
## Planned
2323

24-
- A changelog page generated from [docs/review-ledger.md](docs/review-ledger.md).
2524
- Full-text search over entry bodies (Notes and Evidence), not only names, tags and summaries.
2625

2726
## Done
2827

28+
- A changelog page: [docs/review-ledger.md](docs/review-ledger.md) on the site as guide/changelog/, and the README "Recent" block written from it by `npm run counts`.
2929
- Site search across names, tags and summaries, with licence, format and category filters.
3030
- The guides in docs/ rendered as site pages, and an engine filter that hides projects,
3131
addons and plugins for other engines.

‎docs/review-ledger.md‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,15 @@ Newest section at the top. One section per review run. This is the record of wha
44
run measured, what it changed, what it deliberately did not change, and what the next
55
run should not spend time re-deciding.
66

7+
## 2026-11-07 (audit pass 5 fixes: #246 to #272, then #203, #110, #89, #91)
8+
9+
Worked on main, one commit per issue or pair. Every change ran `npm run check`; the browser-side ones were also clicked through on a local build.
10+
11+
- **Bugs:** logos already in `thumbs.json` → `shared` count toward the three-hash rule (#246); check-added compares UTC days (#247); bot workflows read every open issue (#248); the 404 page suggests stacks (#249); `--stale-days=N` (#250).
12+
- **Site:** one `FILTERS` table behind every catalog filter (#252) and a "Licence read" freshness filter (#271); the homepage uses the shared header and footer (#253); "Add all picks to my shortlist" on stack pages (#272); the shortlist shows what the set owes, and the catalog can copy a link to the view and download the shown results as CSV or JSON (#110); this changelog (#91).
13+
- **Checks and tooling:** one Markdown link reader for validate and the renderer (#254); entry checks run from one registry (#255); one `normalizeEntry` (#256) and one `isListed` (#257); test sections that survive a throw and `TEST_ONLY` (#203); `npm run coverage` (#268); CI on Windows (#267); the link check lists known script-refusing hosts as checked by hand and fetches the licence pages quoted in Evidence (#89).
14+
- **Did not change:** the link checker does not pose as a browser to get past a host's bot blocking (#89 suggested a retry with browser headers). Branch protection (#3) is still a repository setting for the maintainer.
15+
716
## 2026-10-22 (open issues sweep: #77 to #114)
817

918
One branch, seven commits, 23 issues closed. Every change ran `npm test`, `npm run validate` and a full build locally; the incremental build was compared byte for byte with a clean one.

‎site/config.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@
6565
"guides": [
6666
{ "id": "licenses", "title": "Licenses", "path": "docs/licenses.md" },
6767
{ "id": "data", "title": "Use the data (JSON, CSV, feeds)", "path": "docs/data.md" },
68+
{ "id": "changelog", "title": "Changelog (review ledger)", "path": "docs/review-ledger.md" },
6869
{ "id": "for-publishers", "title": "For publishers", "path": "docs/for-publishers.md" },
6970
{ "id": "provenance", "title": "Provenance", "path": "docs/provenance.md" },
7071
{ "id": "high-risk", "title": "Not safe to ship", "path": "docs/high-risk.md" },

‎site/lib/ledger.mjs‎

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
/**
2+
* docs/review-ledger.md, newest section first, as data (#91). The site shows
3+
* the ledger as a guide page (guide/changelog/), and the README "Recent"
4+
* block is written from its newest headings by sync-counts, so neither is
5+
* kept by hand. Pure.
6+
*/
7+
8+
/** Sections headed `## YYYY-MM-DD (title)`, in file order: [{ date, title }]. */
9+
export function ledgerSections(md) {
10+
const out = [];
11+
for (const m of String(md).matchAll(/^## (\d{4}-\d{2}-\d{2}) \((.+)\)\s*$/gm)) out.push({ date: m[1], title: m[2] });
12+
return out;
13+
}
14+
15+
/** The README "Recent" blockquote for the newest `n` sections. */
16+
export function recentBlock(sections, n = 3) {
17+
const rows = sections.slice(0, n).map((s) => `${s.date}, ${s.title}.`);
18+
if (!rows.length) return "";
19+
return [`> **Recent:** ${rows[0]}`, ...rows.slice(1).map((r) => `> ${r}`), "> Every run is in the [changelog](docs/review-ledger.md)."].join("\n");
20+
}
21+
22+
const RECENT_RE = /^> \*\*Recent:\*\*.*(?:\n>.*)*/m;
23+
24+
/** README text with its "Recent" block replaced by `block`; unchanged when it has none. */
25+
export function syncRecentBlock(readme, block) {
26+
return RECENT_RE.test(readme) ? readme.replace(RECENT_RE, () => block) : readme;
27+
}
28+
29+
/** The README's current "Recent" block, or null. */
30+
export function readmeRecentBlock(readme) {
31+
return String(readme).match(RECENT_RE)?.[0] ?? null;
32+
}

‎site/lib/lib.test.mjs‎

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2417,6 +2417,25 @@ await section("link check: manual hosts and licence pages (#89)", async () => {
24172417
}
24182418
});
24192419

2420+
/* review ledger: changelog and README Recent block (#91) ------------------- */
2421+
await section("review ledger: changelog and README Recent block (#91)", async () => {
2422+
const { ledgerSections, recentBlock, syncRecentBlock, readmeRecentBlock } = await import("./ledger.mjs");
2423+
const md = "# Review ledger\n\nIntro.\n\n## 2026-10-22 (open issues sweep)\n\n- a\n\n## Not a dated heading\n\n## 2026-10-13 (Unreal sources)\n\n## 2026-10-04 (video)\n\n## 2026-09-30 (older)\n";
2424+
const secs = ledgerSections(md);
2425+
eq("ledger: dated sections in file order", secs.map((s) => s.date).join(), "2026-10-22,2026-10-13,2026-10-04,2026-09-30");
2426+
eq("ledger: the title is the bracketed text", secs[1].title, "Unreal sources");
2427+
const block = recentBlock(secs);
2428+
has("recent: the newest first", block, "> **Recent:** 2026-10-22, open issues sweep.");
2429+
eq("recent: three sections and the changelog line", block.split("\n").length, 4);
2430+
lacks("recent: the fourth is left out", block, "older");
2431+
const readme = "intro\n\n> **Recent:** old line.\n> another old line.\n\n## Contents\n";
2432+
const synced = syncRecentBlock(readme, block);
2433+
eq("recent: the block is replaced in place", readmeRecentBlock(synced), block);
2434+
has("recent: what follows is kept", synced, "\n\n## Contents\n");
2435+
eq("recent: a README without the block is unchanged", syncRecentBlock("no block", block), "no block");
2436+
eq("recent: no sections, no block", recentBlock([]), "");
2437+
});
2438+
24202439
/* report (keep last) ------------------------------------------------------ */
24212440
if (failures.length) {
24222441
console.error(`lib.test failed (${failures.length}):`);

‎site/lib/shared.mjs‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,7 @@ export function siteFooterHtml({ root, stamp, total, credit = true, current = nu
268268
`<a href="${root}catalog.csv">CSV</a>`,
269269
`<a href="${root}feed.xml">feed</a>`,
270270
`<a href="${root}guide/data/">Use the data</a>`,
271+
`<a href="${root}guide/changelog/">Changelog</a>`,
271272
].filter(Boolean);
272273
return `<footer class="footer">
273274
<p>Catalog metadata is CC0. Linked assets keep their own licences. This is the catalog's reading of each licence, not legal advice: re-check the live source before shipping.</p>

‎site/sync-counts.mjs‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import { fileURLToPath } from "node:url";
1515
import { countEntriesByCategory } from "./lib/entry-files.mjs";
1616
import { syncCatalogReadme, syncConfig, syncReadme } from "./lib/scaffold.mjs";
1717
import { cliArgs } from "./lib/cli.mjs";
18+
import { ledgerSections, recentBlock, syncRecentBlock } from "./lib/ledger.mjs";
1819

1920
// No flags: a mistyped one fails instead of being ignored.
2021
cliArgs({}, "node site/sync-counts.mjs");
@@ -41,6 +42,13 @@ update("README.md", (t) => syncReadme(t, counts, total));
4142
update("catalog/README.md", (t) => syncCatalogReadme(t, counts));
4243
update("site/config.json", (t) => syncConfig(t, files));
4344

45+
// The README "Recent" block, from the newest review-ledger headings (#91).
46+
// Not a count: it does not ask for a new screenshot.
47+
const countsChanged = changed;
48+
const ledger = ledgerSections(fs.readFileSync(path.join(ROOT, "docs", "review-ledger.md"), "utf8"));
49+
update("README.md", (t) => syncRecentBlock(t, recentBlock(ledger)));
50+
changed = countsChanged;
51+
4452
console.log(`${total} listed entries (${files} files, ${deprecated} deprecated): ${Object.entries(counts).map(([c, n]) => `${c} ${n}`).join(", ")}`);
4553
// The README screenshot (also the social card) shows the count as an image,
4654
// which no script can update.

‎site/validate.mjs‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ import {
3131
markdownAnchors,
3232
} from "./checks.mjs";
3333
import { ANY_SCHEME_RE, EXTERNAL_SCHEME_RE, isListed, latestAllowedDate } from "./lib/shared.mjs";
34+
import { ledgerSections, readmeRecentBlock, recentBlock } from "./lib/ledger.mjs";
3435
import { readCatalog } from "./lib/entry-files.mjs";
3536
import { licenceTerms, listStackFiles } from "./lib/stacks.mjs";
3637
import { cliArgs } from "./lib/cli.mjs";
@@ -285,6 +286,13 @@ export function validateRepo() {
285286

286287
errors.push(...checkEntryCount(entryFiles.length, expectedCount));
287288

289+
// The README "Recent" block is written from the review ledger (#91).
290+
const wantRecent = recentBlock(ledgerSections(readText(path.join(ROOT, "docs", "review-ledger.md"))));
291+
const haveRecent = readmeRecentBlock(readText(path.join(ROOT, "README.md")));
292+
if (haveRecent !== null && haveRecent !== wantRecent) {
293+
errors.push('README.md "Recent" block does not match the newest docs/review-ledger.md sections (run npm run counts)');
294+
}
295+
288296
const formPath = path.join(ROOT, ".github", "ISSUE_TEMPLATE", "new-source.yml");
289297
errors.push(
290298
...checkCategorySets({

0 commit comments

Comments
 (0)