BRANCHconstconst BRANCH: "findings-history"The branch that keeps the history.
The history of findings (commons 0038-build-policy FR-012): the orphan branch findings-history of the repository, one new file for each run at runs/YYYY/MM/DD/<workflow>-<run id>.json, written by a commit that adds a file and changes none, pushed as a fast-forward and, where the branch moved meanwhile, retried from the new tip and never forced. Real git is the only thing it uses (no package), so that the job that keeps the history needs nothing installed. read gives the files of the branch for the site, oldest first.
import { BRANCH, runPath } from "./history.ts";
runPath({ id: "9", workflow: "ci", commit: "c", at: "2026-11-22T10:00:00Z" }); // "runs/2026/11/22/ci-9.json"BRANCHconstconst BRANCH: "findings-history"The branch that keeps the history.
runPathfunctionfunction runPath(run: RunInfo): stringWhere the file of a run is on the branch.
Kepttypeno test imports ittype Kept = { readonly kind: "kept"; readonly path: string; readonly attempts: number } | { readonly kind: "exists"; readonly path: string } | { readonly kind: "failed"; readonly error: string };What keeping a run came to.
keepRunfunctionfunction keepRun(_repo: string, remote: string, file: FindingsFile, o?: { readonly attempts?: number | undefined; readonly name?: string | undefined; readonly email?: string | undefined; }): KeptAdds the file of a run to the branch of a repository (remote is the address of the repository, whose branch is read and pushed): the branch is made orphan where it is not there, a file already on it is never replaced, and a push that is not a fast-forward is retried from the new tip, up to attempts times, and never forced.
readHistoryfunctionfunction readHistory(repo: string, ref?: string): readonly { readonly path: string; readonly text: string; }[]The files of the branch that the repository has, oldest first, as text (what the site reads); none where the branch is not there.
readTextconstno test imports itconst readText: (p: string) => string | undefinedThe text of a file of a folder, or undefined.