about summary refs log tree commit diff
path: root/pkgs/applications/misc/genact
diff options
context:
space:
mode:
authorfigsoda <figsoda@pm.me>2022-10-10 09:15:17 -0400
committerfigsoda <figsoda@pm.me>2022-10-10 09:21:57 -0400
commit165b20eafab7f8170fdfb9456ac7b4959a566683 (patch)
tree5b670494bd12eda511c963e393b242b50e7adf5d /pkgs/applications/misc/genact
parent796d4cc2abd7e8b76be12208fe849bee25a2d8a1 (diff)
genact: 1.2.0 -> 1.2.2
Diffstat (limited to 'pkgs/applications/misc/genact')
-rw-r--r--pkgs/applications/misc/genact/default.nix20
1 files changed, 16 insertions, 4 deletions
diff --git a/pkgs/applications/misc/genact/default.nix b/pkgs/applications/misc/genact/default.nix
index cb08cfb334a29..061fce572631a 100644
--- a/pkgs/applications/misc/genact/default.nix
+++ b/pkgs/applications/misc/genact/default.nix
@@ -1,17 +1,29 @@
-{ lib, rustPlatform, fetchFromGitHub }:
+{ lib, rustPlatform, fetchFromGitHub, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "genact";
-  version = "1.2.0";
+  version = "1.2.2";
 
   src = fetchFromGitHub {
     owner = "svenstaro";
     repo = pname;
     rev = "v${version}";
-    sha256 = "sha256-POOXawhxrPT2UgbSZE3r0br7cqJ0ao7MpycrPYa/oCc=";
+    sha256 = "sha256-MB/i1jCxoGE8cPF+NE8aS7kF7ZsGb4+OyLcPcGp1hwI=";
   };
 
-  cargoSha256 = "sha256-2c34YarMFw2CK+7zn41GL5tXfXfnw3NvGtgSlPH5d64=";
+  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";