Answer stability round 1: 0 🔴, 3 🟡 (0 misread); the description test refuses an empty one and needs a sentence start, the PATCH body is a tested pure function, the trial-stack block moves to Quick start

This commit is contained in:
2026-10-31 11:19:11 +01:00
parent 1adeb776a2
commit 282c4b17da
3 changed files with 14 additions and 9 deletions
+5 -4
View File
@@ -1,6 +1,3 @@
// Publishes the Docker Hub repository overview from dockerhub-overview.md.tmpl, rendering
// `{{VERSION}}` to the release being published, and the short description.
import { readFileSync } from "node:fs";
import { join } from "node:path";
@@ -10,6 +7,10 @@ const VERSION = /^\d+\.\d+\.\d+$/;
export const DESCRIPTION = "A self-hostable foundation for server-rendered web applications";
export function hubPatch(overview: string): { description: string; full_description: string } {
return { description: DESCRIPTION, full_description: overview };
}
export function renderOverview(source: string, version: string): string {
return source.replaceAll("{{VERSION}}", version);
}
@@ -83,7 +84,7 @@ async function main(): Promise<number> {
if (!jwt) return fail("Docker Hub login returned no token");
const res = await post(`${HUB}/repositories/${repo}/`, {
body: JSON.stringify({ description: DESCRIPTION, full_description: body }),
body: JSON.stringify(hubPatch(body)),
headers: { authorization: `Bearer ${jwt}`, "content-type": "application/json" },
method: "PATCH",
});