Compare commits

..

2 commits

Author SHA1 Message Date
atagen
e44c71c128 switch to homegrown pinning
All checks were successful
Nix Build / nix build (push) Successful in 6s
2026-05-20 15:26:40 +10:00
atagen
2d564db596 nu 2026-05-20 15:26:31 +10:00

View file

@ -46,7 +46,7 @@ def nix-build-nom [out: string, source: string, attr: string, extras: list<strin
if ($env.MONITOR? | is-empty) {
^nix-build --out-link $out $source -A $attr ...$extras
} else {
^nix-build --log-format internal-json -v --out-link $out $source -A $attr ...$extras out+err>| ^$env.MONITOR --json
^nix-build --log-format internal-json --out-link $out $source -A $attr ...$extras out+err>| ^$env.MONITOR --json
}
}
@ -181,8 +181,9 @@ def ls-remote-head [url: string] {
# Real prefetch — caches in /nix/store and returns the full locked attrset.
# Output JSON: { hash: SRI, locked: {...}, original: {...}, storePath: PATH }
# --refresh bypasses the ref→rev cache (otherwise stale within tarball-ttl).
def prefetch-pin [url: string] {
let r = ^nix flake prefetch --json $url | complete
let r = ^nix flake prefetch --refresh --json $url | complete
if $r.exit_code != 0 { error make { msg: $"prefetch failed for ($url): ($r.stderr)" } }
let j = $r.stdout | from json
$j.locked | insert narHash $j.hash