keep-sorted: 0.5.1 -> 0.6.0 (#375017)

authored by Paul Meyer and committed by GitHub 564ebcad 25d6e81e

+16 -5
+16 -5
pkgs/by-name/ke/keep-sorted/package.nix
··· 1 { 2 lib, 3 - buildGo123Module, 4 fetchFromGitHub, 5 nix-update-script, 6 }: 7 8 - buildGo123Module rec { 9 pname = "keep-sorted"; 10 - version = "0.5.1"; 11 12 src = fetchFromGitHub { 13 owner = "google"; 14 repo = "keep-sorted"; 15 - rev = "v${version}"; 16 - hash = "sha256-xvSEREEOiwft3fPN+xtdMCh+z3PknjJ962Nb+pw715U="; 17 }; 18 19 vendorHash = "sha256-HTE9vfjRmi5GpMue7lUfd0jmssPgSOljbfPbya4uGsc="; 20 21 env.CGO_ENABLED = "0"; 22 23 ldflags = [ "-s" ]; ··· 26 # Test tries to find files using git in init func. 27 rm goldens/*_test.go 28 ''; 29 30 passthru.updateScript = nix-update-script { }; 31
··· 1 { 2 lib, 3 + buildGoModule, 4 fetchFromGitHub, 5 nix-update-script, 6 + versionCheckHook, 7 }: 8 9 + buildGoModule rec { 10 pname = "keep-sorted"; 11 + version = "0.6.0"; 12 13 src = fetchFromGitHub { 14 owner = "google"; 15 repo = "keep-sorted"; 16 + tag = "v${version}"; 17 + hash = "sha256-ROvj7w8YMq6+ntx0SWi+HfN4sO6d7RjKWwlb/9gfz8w="; 18 }; 19 20 vendorHash = "sha256-HTE9vfjRmi5GpMue7lUfd0jmssPgSOljbfPbya4uGsc="; 21 22 + # Inject version string instead of reading version from buildinfo. 23 + postPatch = '' 24 + substituteInPlace main.go \ 25 + --replace-fail 'readVersion())' '"v${version}")' 26 + ''; 27 + 28 env.CGO_ENABLED = "0"; 29 30 ldflags = [ "-s" ]; ··· 33 # Test tries to find files using git in init func. 34 rm goldens/*_test.go 35 ''; 36 + 37 + nativeInstallCheckInputs = [ versionCheckHook ]; 38 + 39 + doInstallCheck = true; 40 41 passthru.updateScript = nix-update-script { }; 42