nixpkgs/pkgs/development/tools/exhaustive/default.nix
stuebinm ff1a94e523 treewide: add meta.mainProgram to packages with a single binary
The nixpkgs-unstable channel's programs.sqlite was used to identify
packages producing exactly one binary, and these automatically added
to their package definitions wherever possible.
2024-03-19 03:14:51 +01:00

29 lines
674 B
Nix

{ lib
, buildGoModule
, fetchFromGitHub
}:
buildGoModule rec {
pname = "exhaustive";
version = "0.10.0";
src = fetchFromGitHub {
owner = "nishanths";
repo = "exhaustive";
rev = "v${version}";
hash = "sha256-vMoFIyZcAdObeQD5bGcQHlGpJv/a8yl/2HUVc8aDiIA=";
};
vendorHash = "sha256-i3Cgefe4krvH99N233IeEWkVt9AhdzROkJ5JBeTIaAs=";
ldflags = [ "-s" "-w" ];
meta = with lib; {
description = "Check exhaustiveness of switch statements of enum-like constants in Go code";
mainProgram = "exhaustive";
homepage = "https://github.com/nishanths/exhaustive";
license = licenses.bsd2;
maintainers = with maintainers; [ meain ];
};
}