2023-05-20 13:17:49 +02:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
2023-05-29 20:07:30 +02:00
|
|
|
, testers
|
|
|
|
, bearer
|
2023-05-20 13:17:49 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "bearer";
|
2023-09-07 01:42:21 +02:00
|
|
|
version = "1.22.0";
|
2023-05-20 13:17:49 +02:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "bearer";
|
|
|
|
repo = "bearer";
|
|
|
|
rev = "refs/tags/v${version}";
|
2023-09-07 01:42:21 +02:00
|
|
|
hash = "sha256-nRtbWefRtV9wD4rmnbiZQa0R5JuW8Vs5NRTWBNH4ydc=";
|
2023-05-20 13:17:49 +02:00
|
|
|
};
|
|
|
|
|
2023-09-07 01:42:21 +02:00
|
|
|
vendorHash = "sha256-rvL2/YrwkKHs6fTEg3MG2uRx+ii8Hg8c2wPly9In1E8=";
|
2023-05-20 13:17:49 +02:00
|
|
|
|
|
|
|
subPackages = [
|
|
|
|
"cmd/bearer"
|
|
|
|
];
|
|
|
|
|
|
|
|
ldflags = [
|
|
|
|
"-s"
|
|
|
|
"-w"
|
2023-05-29 20:05:21 +02:00
|
|
|
"-X=github.com/bearer/bearer/cmd/bearer/build.Version=${version}"
|
2023-05-20 13:17:49 +02:00
|
|
|
];
|
|
|
|
|
2023-05-29 20:07:30 +02:00
|
|
|
passthru.tests = {
|
|
|
|
version = testers.testVersion {
|
|
|
|
package = bearer;
|
|
|
|
command = "bearer version";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-05-20 13:17:49 +02:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Code security scanning tool (SAST) to discover, filter and prioritize security and privacy risks";
|
|
|
|
homepage = "https://github.com/bearer/bearer";
|
|
|
|
changelog = "https://github.com/Bearer/bearer/releases/tag/v${version}";
|
|
|
|
license = with licenses; [ elastic ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|