update to nixUnstable

This commit is contained in:
steveej 2022-01-03 21:03:05 +01:00
parent d20830e4d1
commit c2aa524d64
2 changed files with 4 additions and 1 deletions

View file

@ -2,5 +2,7 @@
set -xe
INFILE="${1:?Please set arg1 to INFILE}"
OUTFILE="${2:?Please set arg2 to OUTFILE}"
hash=$(nix-build ${INFILE} --arg pkgs 'import <channels-nixos-stable> {}' --arg config 'null' 2>&1 | rg -o 'got.*sha256:([0-9a-z]{52})' -r '$1')
# sha256-1fm94N2Y9ptXVN6ni0nJyPRK+nsvoeliqBcFyjlaTH4=
hash=$(nix-build ${INFILE} --arg pkgs 'import <channels-nixos-stable> {}' --arg config 'null' 2>&1 | rg -o 'got.*(sha256-.{44})' -r '$1')
sed -E "s/0{52}/${hash}/" ${INFILE} > ${OUTFILE}