2022-08-05 14:27:34 +00:00
|
|
|
{ stdenv, buildGoModule, fetchFromGitHub, lib }:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "moq";
|
2023-10-16 11:54:30 +00:00
|
|
|
version = "0.3.3";
|
2022-08-05 14:27:34 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "matryer";
|
|
|
|
repo = "moq";
|
|
|
|
rev = "v${version}";
|
2023-10-16 11:54:30 +00:00
|
|
|
sha256 = "sha256-TOFWaPJ+XfgiQCVRXze29TG7Zfur0SV4mQNdgVIGj5o=";
|
2022-08-05 14:27:34 +00:00
|
|
|
};
|
|
|
|
|
2023-03-10 01:11:52 +00:00
|
|
|
vendorHash = "sha256-lfs61YK5HmUd3/qA4o9MiWeTFhu4MTAkNH+f0iGlRe0=";
|
2022-08-05 14:27:34 +00:00
|
|
|
|
|
|
|
subPackages = [ "." ];
|
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
|
|
|
"-X main.Version=${version}"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/matryer/moq";
|
|
|
|
description = "Interface mocking tool for go generate";
|
|
|
|
longDescription = ''
|
|
|
|
Moq is a tool that generates a struct from any interface. The struct can
|
|
|
|
be used in test code as a mock of the interface.
|
|
|
|
'';
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ anpryl ];
|
|
|
|
};
|
|
|
|
}
|