depot/third_party/nixpkgs/pkgs/applications/misc/genact/default.nix
Default email c594a97518 Project import generated by Copybara.
GitOrigin-RevId: 301aada7a64812853f2e2634a530ef5d34505048
2022-10-21 20:38:19 +02:00

35 lines
1 KiB
Nix

{ lib, rustPlatform, fetchFromGitHub, installShellFiles }:
rustPlatform.buildRustPackage rec {
pname = "genact";
version = "1.2.2";
src = fetchFromGitHub {
owner = "svenstaro";
repo = pname;
rev = "v${version}";
sha256 = "sha256-MB/i1jCxoGE8cPF+NE8aS7kF7ZsGb4+OyLcPcGp1hwI=";
};
cargoSha256 = "sha256-OBGJIR3REeMxHQu3ovEKSZZ8QNlhl/5jvWbR5OdsRTQ=";
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
$out/bin/genact --print-manpage > genact.1
installManPage genact.1
installShellCompletion --cmd genact \
--bash <($out/bin/genact --print-completions bash) \
--fish <($out/bin/genact --print-completions fish) \
--zsh <($out/bin/genact --print-completions zsh)
'';
meta = with lib; {
description = "A nonsense activity generator";
homepage = "https://github.com/svenstaro/genact";
changelog = "https://github.com/svenstaro/genact/blob/v${version}/CHANGELOG.md";
license = licenses.mit;
maintainers = with maintainers; [ figsoda ];
};
}