From 7e5a7f5a6c66f9481ebfb89c4ba940f9d0a67590 Mon Sep 17 00:00:00 2001 From: phanirithvij Date: Fri, 13 Jun 2025 23:28:58 +0530 Subject: [PATCH 1/2] gotools: 0.30.0 -> 0.34.0 Signed-off-by: phanirithvij (cherry picked from commit 2b0f44416890ad41a4d7a4f02f541bc68467b0bb) --- pkgs/by-name/go/gotools/package.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/by-name/go/gotools/package.nix b/pkgs/by-name/go/gotools/package.nix index ab00c3f10ef6..ed9cdf1d9c1b 100644 --- a/pkgs/by-name/go/gotools/package.nix +++ b/pkgs/by-name/go/gotools/package.nix @@ -8,20 +8,20 @@ buildGoModule rec { pname = "gotools"; - version = "0.30.0"; + version = "0.34.0"; # using GitHub instead of https://go.googlesource.com/tools because Gitiles UI is to basic to browse src = fetchFromGitHub { owner = "golang"; repo = "tools"; rev = "v${version}"; - hash = "sha256-yUkdZSe/GV0w1qK8aQjcFE4tNKYC8f4JeFgPiv8GlQc="; + hash = "sha256-C+P2JoD4NzSAkAQuA20bVrfLZrMHXekvXn8KPOM5Nj4="; }; allowGoReference = true; doCheck = false; - vendorHash = "sha256-+jhCNi7bGkRdI1Ywfe3q4i+zcm3UJ0kbQalsDD3WkS4="; + vendorHash = "sha256-UZNYHx5y+kRp3AJq6s4Wy+k789GDG7FBTSzCTorVjgg="; nativeBuildInputs = [ makeWrapper ]; @@ -29,6 +29,8 @@ buildGoModule rec { # The gopls folder contains a Go submodule which causes a build failure # and lives in its own package named gopls. rm -r gopls + # cmd/auth folder is similar and is scheduled to be removed https://github.com/golang/go/issues/70872 + rm -r cmd/auth ''; # Set GOTOOLDIR for derivations adding this to buildInputs From 9ca0462ebbd5068bc58d0ca806e75d3fcb98e699 Mon Sep 17 00:00:00 2001 From: phanirithvij Date: Fri, 13 Jun 2025 23:29:06 +0530 Subject: [PATCH 2/2] gotools: modernize derivation Signed-off-by: phanirithvij (cherry picked from commit 4d612f08bab8acfcdd44a60a697b1b4279318d27) --- pkgs/by-name/go/gotools/package.nix | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pkgs/by-name/go/gotools/package.nix b/pkgs/by-name/go/gotools/package.nix index ed9cdf1d9c1b..74392d52e6eb 100644 --- a/pkgs/by-name/go/gotools/package.nix +++ b/pkgs/by-name/go/gotools/package.nix @@ -6,15 +6,15 @@ go, }: -buildGoModule rec { +buildGoModule (finalAttrs: { pname = "gotools"; version = "0.34.0"; - # using GitHub instead of https://go.googlesource.com/tools because Gitiles UI is to basic to browse + # using GitHub instead of https://go.googlesource.com/tools because Gitiles UI is too basic to browse src = fetchFromGitHub { owner = "golang"; repo = "tools"; - rev = "v${version}"; + tag = "v${finalAttrs.version}"; hash = "sha256-C+P2JoD4NzSAkAQuA20bVrfLZrMHXekvXn8KPOM5Nj4="; }; @@ -45,16 +45,16 @@ buildGoModule rec { --suffix PATH : ${lib.makeBinPath [ go ]} ''; - meta = with lib; { + meta = { description = "Additional tools for Go development"; longDescription = '' This package contains tools like: godoc, goimports, callgraph, digraph, stringer or toolstash. ''; homepage = "https://go.googlesource.com/tools"; - license = licenses.bsd3; - maintainers = with maintainers; [ + license = lib.licenses.bsd3; + maintainers = with lib.maintainers; [ SuperSandro2000 techknowlogick ]; }; -} +})