From 888a8063354659fa17c0a3b4d6f5b61536c307bc Mon Sep 17 00:00:00 2001 From: 06kellyjac Date: Tue, 9 Mar 2021 18:25:11 +0000 Subject: [PATCH] nerdctl: 0.6.1 -> 0.7.0 Set buildFlagsArray using bash Completions have been added but the command will fail without access to a containerd socket --- .../networking/cluster/nerdctl/default.nix | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/pkgs/applications/networking/cluster/nerdctl/default.nix b/pkgs/applications/networking/cluster/nerdctl/default.nix index b16d0448cadc..2fc858860e12 100644 --- a/pkgs/applications/networking/cluster/nerdctl/default.nix +++ b/pkgs/applications/networking/cluster/nerdctl/default.nix @@ -9,26 +9,26 @@ buildGoModule rec { pname = "nerdctl"; - version = "0.6.1"; + version = "0.7.0"; src = fetchFromGitHub { owner = "AkihiroSuda"; repo = pname; rev = "v${version}"; - sha256 = "sha256-zexvTPEQw7iW1d3ahHmqTn+UaT/bJMlr1sVlWErc2ck="; + sha256 = "sha256-z5Ekryaa5KMShrjdsmFk9bXahtuc+6tec7dxH5/w7+A="; }; - vendorSha256 = "sha256-bX1GfKbAbdEAnW3kPNsbF/cJWufxvuhm//G88qJ3u08="; + vendorSha256 = "sha256-ovmVNtzTQbg141IvbaF/+k5WHxX8wuK7z5gH9l2g5UE="; nativeBuildInputs = [ makeWrapper ]; - buildFlagsArray = [ - "-ldflags=" - "-w" - "-s" - "-X github.com/AkihiroSuda/nerdctl/pkg/version.Version=v${version}" - "-X github.com/AkihiroSuda/nerdctl/pkg/version.Revision=" - ]; + preBuild = + let + t = "github.com/AkihiroSuda/nerdctl/pkg/version"; + in + '' + buildFlagsArray+=("-ldflags" "-s -w -X ${t}.Version=v${version} -X ${t}.Revision=") + ''; # Many checks require a containerd socket and running nerdctl after it's built doCheck = false;