nixpkgs/pkgs/development/tools/bingo/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

44 lines
1.1 KiB
Nix
Raw Normal View History

{ lib, buildGoModule, fetchFromGitHub, testers, bingo }:
2022-02-02 02:11:01 +00:00
buildGoModule rec {
pname = "bingo";
2022-04-25 08:43:48 +00:00
version = "0.6.0";
2022-02-02 02:11:01 +00:00
src = fetchFromGitHub {
owner = "bwplotka";
repo = "bingo";
rev = "v${version}";
2022-04-25 08:43:48 +00:00
sha256 = "sha256-t2nkY+mwek2NcbCwCkI3Mc1ULEJIjatBjChBdnKFAg8=";
2022-02-02 02:11:01 +00:00
};
2022-04-25 08:43:48 +00:00
vendorSha256 = "sha256-TCbwIHDg2YaLIscCoGPRBv5G3YSJ+qn/koOjPh+KKRY=";
2022-02-02 02:11:01 +00:00
patches = [
# Do not execute `go` command when invoking `bingo version`.
./version_go.patch
2022-04-25 08:43:48 +00:00
# Specific to v0.6.0. `v0.6` -> `v0.6.0`
./bingo_version.patch
2022-02-02 02:11:01 +00:00
];
postPatch = ''
rm get_e2e_test.go get_e2e_utils_test.go
'';
CGO_ENABLED = 0;
ldflags = [ "-s" "-w" ];
passthru.tests.version = testers.testVersion {
2022-02-02 02:11:01 +00:00
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";
license = licenses.asl20;
maintainers = with maintainers; [ aaronjheng ];
};
}