Files
nixpkgs/pkgs/by-name/tw/twm/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

54 lines
1.2 KiB
Nix

{
lib,
fetchFromGitHub,
stdenv,
rustPlatform,
openssl,
pkg-config,
nix-update-script,
installShellFiles,
}:
rustPlatform.buildRustPackage rec {
pname = "twm";
version = "0.12.3";
src = fetchFromGitHub {
owner = "vinnymeller";
repo = "twm";
tag = "v${version}";
hash = "sha256-Hta9IvPViZFEiR+RXRmlPRwIu10D9B5dbXzhflxzBhY=";
};
cargoHash = "sha256-buiU+umHqyZ/3YoW2+5QpmF9AGEuNUihro5PFuWFSH4=";
nativeBuildInputs = [
pkg-config
installShellFiles
];
buildInputs = [
openssl
];
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd twm \
--bash <($out/bin/twm --print-bash-completion) \
--zsh <($out/bin/twm --print-zsh-completion) \
--fish <($out/bin/twm --print-fish-completion)
$out/bin/twm --print-man > twm.1
installManPage twm.1
'';
passthru.updateScript = nix-update-script { };
meta = {
description = "Customizable workspace manager for tmux";
homepage = "https://github.com/vinnymeller/twm";
changelog = "https://github.com/vinnymeller/twm/releases/tag/v${version}";
license = lib.licenses.mit;
maintainers = [ lib.maintainers.vinnymeller ];
mainProgram = "twm";
};
}