Merge pull request #228152 from figsoda/trufflehog
trufflehog: fix version
This commit is contained in:
commit
1dc0c7728d
1 changed files with 14 additions and 0 deletions
|
@ -1,6 +1,8 @@
|
|||
{ lib
|
||||
, fetchFromGitHub
|
||||
, buildGoModule
|
||||
, testers
|
||||
, trufflehog
|
||||
}:
|
||||
|
||||
buildGoModule rec {
|
||||
|
@ -16,6 +18,12 @@ buildGoModule rec {
|
|||
|
||||
vendorHash = "sha256-sSpRu6zLIvllrDYdtrj3oD3pCVs9ucSXbu3IYTqjT+k=";
|
||||
|
||||
ldflags = [
|
||||
"-s"
|
||||
"-w"
|
||||
"-X=github.com/trufflesecurity/trufflehog/v3/pkg/version.BuildVersion=${version}"
|
||||
];
|
||||
|
||||
# Test cases run git clone and require network access
|
||||
doCheck = false;
|
||||
|
||||
|
@ -23,6 +31,12 @@ buildGoModule rec {
|
|||
rm $out/bin/{generate,snifftest}
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
tests.version = testers.testVersion {
|
||||
package = trufflehog;
|
||||
};
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "Find credentials all over the place";
|
||||
homepage = "https://github.com/trufflesecurity/trufflehog";
|
||||
|
|
Loading…
Reference in a new issue