godns: modernize

This commit is contained in:
Fabian Affolter 2023-03-03 13:08:06 +01:00 committed by GitHub
parent 76ba8f5d3c
commit a9ea617e3a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,4 +1,8 @@
{ buildGoModule, fetchFromGitHub, lib, nix-update-script }:
{ lib
, buildGoModule
, fetchFromGitHub
, nix-update-script
}:
buildGoModule rec {
pname = "godns";
@ -7,16 +11,20 @@ buildGoModule rec {
src = fetchFromGitHub {
owner = "TimothyYe";
repo = "godns";
rev = "v${version}";
sha256 = "sha256-7AIr35vsjI5jamvdA1EwTwkr8MiEOjTntFeeg4b7RCw=";
rev = "refs/tags/v${version}";
hash = "sha256-7AIr35vsjI5jamvdA1EwTwkr8MiEOjTntFeeg4b7RCw=";
};
vendorSha256 = "sha256-+wnaTrY7Mt6bCNTRZbJDFD75RCHyz5gtFi4DN0ng0/M=";
vendorHash = "sha256-+wnaTrY7Mt6bCNTRZbJDFD75RCHyz5gtFi4DN0ng0/M=";
# Some tests require internet access, broken in sandbox
doCheck = false;
ldflags = [ "-s" "-w" "-X main.Version=${version}" ];
ldflags = [
"-s"
"-w"
"-X main.Version=${version}"
];
passthru.updateScript = nix-update-script { };