Ignore a package preview made by another nixos-router
A preview is kept until the next one; after an update it could still show the list the older version made. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AeFqV9dZrK6nipHkPfyM4F
This commit is contained in:
@@ -190,10 +190,11 @@ let
|
||||
builds=$(grep -cE '^ +/nix/store/[^ ]*\.drv$' <<<"$dry" || true)
|
||||
echo " to fetch: ''${download:-nothing, or no cache reachable}; to build here: $builds"
|
||||
|
||||
jq -n --arg channel "$channel" --arg rev "$newest" --arg ref "$pin" --arg version "$new_version" \
|
||||
release_version=$(jq -r '.version // ""' /etc/router-release 2>/dev/null || true)
|
||||
jq -n --arg channel "$channel" --arg release "$release_version" --arg rev "$newest" --arg ref "$pin" --arg version "$new_version" \
|
||||
--arg time "$(date -u +%FT%TZ)" --arg download "$download" --argjson builds "$builds" \
|
||||
--argjson reboot "$reboot" --slurpfile changes ${dir}/changes.json \
|
||||
'{channel: $channel, rev: $rev, ref: $ref, version: $version, time: $time, download: $download,
|
||||
'{channel: $channel, release: $release, rev: $rev, ref: $ref, version: $version, time: $time, download: $download,
|
||||
builds: $builds, rebootNeeded: $reboot, changes: $changes[0]}' > ${dir}/preview.json
|
||||
echo "$new_version$([ "$reboot" = false ] || echo ' (a new kernel runs after a reboot)'): router-upgrade apply activates it"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user