Files
nixpkgs/pkgs/by-name/go/goconst/package.nix
2025-05-23 01:10:45 +00:00

36 lines
710 B
Nix

{
lib,
buildGoModule,
fetchFromGitHub,
}:
buildGoModule rec {
pname = "goconst";
version = "1.8.2";
excludedPackages = [ "tests" ];
src = fetchFromGitHub {
owner = "jgautheron";
repo = "goconst";
rev = "v${version}";
sha256 = "sha256-srBUqWfiuMqpKH/O66gJEEKFOC/ifsu2xscEnp54cRY=";
};
vendorHash = null;
ldflags = [
"-s"
"-w"
];
meta = with lib; {
description = "Find in Go repeated strings that could be replaced by a constant";
mainProgram = "goconst";
homepage = "https://github.com/jgautheron/goconst";
license = licenses.mit;
maintainers = with maintainers; [ kalbasit ];
platforms = platforms.linux ++ platforms.darwin;
};
}