depot/third_party/nixpkgs/pkgs/tools/security/gopass/summon.nix
Default email 5e7c2d6cef Project import generated by Copybara.
GitOrigin-RevId: f99e5f03cc0aa231ab5950a15ed02afec45ed51a
2023-10-09 21:29:22 +02:00

42 lines
1 KiB
Nix

{ lib
, makeWrapper
, buildGoModule
, fetchFromGitHub
, gopass
}:
buildGoModule rec {
pname = "gopass-summon-provider";
version = "1.15.8";
src = fetchFromGitHub {
owner = "gopasspw";
repo = "gopass-summon-provider";
rev = "v${version}";
hash = "sha256-7Oj/1h1468zz6r3+Cv5IaIFbkrs0dPteY0SRsOZ8UXI=";
};
vendorHash = "sha256-IXY8w5TLXA3SIT2Jyjqt+pPtZ35zQnG0wY08OB1spDw=";
subPackages = [ "." ];
nativeBuildInputs = [ makeWrapper ];
ldflags = [
"-s" "-w" "-X main.version=${version}" "-X main.commit=${src.rev}"
];
postFixup = ''
wrapProgram $out/bin/gopass-summon-provider \
--prefix PATH : "${lib.makeBinPath [ gopass ]}"
'';
meta = with lib; {
description = "Gopass Summon Provider";
homepage = "https://github.com/gopasspw/gopass-summon-provider";
changelog = "https://github.com/gopasspw/gopass-summon-provider/blob/v${version}/CHANGELOG.md";
license = licenses.mit;
maintainers = with maintainers; [ sikmir ];
mainProgram = "gopass-summon-provider";
};
}