1
0
mirror of https://github.com/goreleaser/goreleaser.git synced 2025-01-06 03:13:48 +02:00
goreleaser/scripts/nix-update-flake.sh
2024-11-07 13:33:54 -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