[repo] Release: version 1.0.0, its notes, About shows the running version; nix-pin --check prints the pin it would write

This commit is contained in:
2026-12-02 13:00:45 +01:00
parent 3bf4a4f4d2
commit 54e186f332
10 changed files with 50 additions and 11 deletions
+7 -1
View File
@@ -59,7 +59,13 @@ new=$(printf '%s\n' "${entries[@]}" | jq -s --arg v "$version" --arg sys "$syste
'{version: $v, system: $sys, commit: $c, sourceTree: $t, nixpkgs: $n, outputs: add}')
if [ "$mode" = --check ]; then
[ -f "$pin" ] || { echo "no $pin to check" >&2; exit 1; }
# With no pin yet, print the one this build would write: the NixOS runner has no commit rights, so its
# log is how the first pin of a release reaches the repo (docs/release.md, Handover 1a).
if [ ! -f "$pin" ]; then
echo "no $pin to check; this build's pin would be:" >&2
jq -S -c . <<<"$new" | sed 's/^/pin.json: /' >&2
exit 1
fi
# At a tag the commit is the pin's child (only pin.json differs), so the commit itself is not
# compared; the source tree, nixpkgs and every hash are.
if [ "$(jq -S 'del(.commit)' "$pin")" != "$(jq -S 'del(.commit)' <<<"$new")" ]; then