From 16085338c099f5882101c4ed8160c6a4ab97f001 Mon Sep 17 00:00:00 2001 From: Aaron Jheng Date: Wed, 12 Oct 2022 08:22:32 +0000 Subject: [PATCH] bingo: 0.6.0 -> 0.7.0 --- .../tools/bingo/bingo_version.patch | 13 ------------ pkgs/development/tools/bingo/default.nix | 21 ++++--------------- pkgs/development/tools/bingo/version_go.patch | 17 --------------- 3 files changed, 4 insertions(+), 47 deletions(-) delete mode 100644 pkgs/development/tools/bingo/bingo_version.patch delete mode 100644 pkgs/development/tools/bingo/version_go.patch diff --git a/pkgs/development/tools/bingo/bingo_version.patch b/pkgs/development/tools/bingo/bingo_version.patch deleted file mode 100644 index a3d85df6a9ce..000000000000 --- a/pkgs/development/tools/bingo/bingo_version.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/pkg/version/version.go b/pkg/version/version.go -index 30f8f30..11c12a0 100644 ---- a/pkg/version/version.go -+++ b/pkg/version/version.go -@@ -6,7 +6,7 @@ package version - import "github.com/Masterminds/semver" - - // Version returns 'bingo' version. --const Version = "v0.6" -+const Version = "v0.6.0" - - var ( - Go114 = semver.MustParse("1.14") diff --git a/pkgs/development/tools/bingo/default.nix b/pkgs/development/tools/bingo/default.nix index 1b4ddd41c0e3..0c0d90bb9fc9 100644 --- a/pkgs/development/tools/bingo/default.nix +++ b/pkgs/development/tools/bingo/default.nix @@ -1,24 +1,17 @@ -{ lib, buildGoModule, fetchFromGitHub, testers, bingo }: +{ lib, buildGoModule, fetchFromGitHub }: buildGoModule rec { pname = "bingo"; - version = "0.6.0"; + version = "0.7.0"; src = fetchFromGitHub { owner = "bwplotka"; repo = "bingo"; rev = "v${version}"; - sha256 = "sha256-t2nkY+mwek2NcbCwCkI3Mc1ULEJIjatBjChBdnKFAg8="; + sha256 = "sha256-s+vdtMzeHUtUlmMlvgnK83RYoMqS3GqrTnu7LssIK6A="; }; - vendorSha256 = "sha256-TCbwIHDg2YaLIscCoGPRBv5G3YSJ+qn/koOjPh+KKRY="; - - patches = [ - # Do not execute `go` command when invoking `bingo version`. - ./version_go.patch - # Specific to v0.6.0. `v0.6` -> `v0.6.0` - ./bingo_version.patch - ]; + vendorSha256 = "sha256-28p1g+p+guJ0x4/5QDGsGN6gDnZkE4AKF/2cFgNjPDM="; postPatch = '' rm get_e2e_test.go get_e2e_utils_test.go @@ -28,12 +21,6 @@ buildGoModule rec { ldflags = [ "-s" "-w" ]; - passthru.tests.version = testers.testVersion { - package = bingo; - command = "bingo version"; - version = "v${version}"; - }; - meta = with lib; { description = "Like `go get` but for Go tools! CI Automating versioning of Go binaries in a nested, isolated Go modules."; homepage = "https://github.com/bwplotka/bingo"; diff --git a/pkgs/development/tools/bingo/version_go.patch b/pkgs/development/tools/bingo/version_go.patch deleted file mode 100644 index 2898326a0547..000000000000 --- a/pkgs/development/tools/bingo/version_go.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git a/main.go b/main.go -index 5600f7e..662ed1b 100644 ---- a/main.go -+++ b/main.go -@@ -201,10 +201,8 @@ func main() { - return pkgs.PrintTab(target, os.Stdout) - } - case "version": -- cmdFunc = func(ctx context.Context, r *runner.Runner) error { -- _, err := fmt.Fprintln(os.Stdout, version.Version) -- return err -- } -+ _, _ = fmt.Fprintln(os.Stdout, version.Version) -+ return - default: - exitOnUsageError(flags.Usage, "No such command", flags.Arg(0)) - }