1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-08 03:31:59 +02:00
goreleaser/scripts/nix-udpate-flake.sh
2024-02-12 23:22:55 -03:00

7 lines
296 B
Bash
Executable File

#!/bin/sh
NEW_HASH="$(nix-prefetch \
--option extra-experimental-features flakes \
'{ sha256 }: (builtins.getFlake (toString ./.)).packages.x86_64-linux.default.goModules.overrideAttrs (_: { vendorSha256 = sha256; })')"
sed -i "s|vendorHash = \".*\"|vendorHash = \"${NEW_HASH}\"|" ./flake.nix