2021-02-05 17:12:51 +00:00
|
|
|
{ lib, rustPlatform, fetchFromGitHub, installShellFiles }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "tydra";
|
2024-06-24 18:47:55 +00:00
|
|
|
version = "1.0.3";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Mange";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2024-06-24 18:47:55 +00:00
|
|
|
sha256 = "sha256-bH/W54b7UHdkbgLXAd+l5I6UAKjWDMW+I5mfwT4yEEY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-06-24 18:47:55 +00:00
|
|
|
cargoHash = "sha256-emZWQHOgYUQzCa/SmztSLa19bB1aJpPUiBg2C7w6W8M=";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installManPage doc/{tydra.1,tydra-actions.5}
|
|
|
|
|
|
|
|
$out/bin/tydra --generate-completions bash > tydra.bash
|
|
|
|
$out/bin/tydra --generate-completions fish > tydra.fish
|
|
|
|
$out/bin/tydra --generate-completions zsh > _tydra
|
|
|
|
|
|
|
|
installShellCompletion tydra.{bash,fish} _tydra
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Shortcut menu-based task runner, inspired by Emacs Hydra";
|
|
|
|
homepage = "https://github.com/Mange/tydra";
|
|
|
|
license = licenses.mit;
|
2020-11-19 00:13:47 +00:00
|
|
|
maintainers = with maintainers; [ Br1ght0ne ];
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "tydra";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|