2023-07-26 04:42:08 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, installShellFiles
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "hyprdim";
|
2023-08-13 23:05:15 +00:00
|
|
|
version = "2.2.1";
|
2023-07-26 04:42:08 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "donovanglover";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2023-08-13 23:05:15 +00:00
|
|
|
hash = "sha256-6HeVLgEJDPy4cWL5td3Xl7+a6WUFZWUFynvBzPhItcg=";
|
2023-07-26 04:42:08 +00:00
|
|
|
};
|
|
|
|
|
2023-08-13 23:05:15 +00:00
|
|
|
cargoHash = "sha256-qYX5o64X8PsFcTYuZ82lIShyUN69oTzQIHrQH4B7iIw=";
|
2023-07-26 04:42:08 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
installShellFiles
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installManPage man/hyprdim.1
|
|
|
|
|
|
|
|
installShellCompletion --cmd hyprdim \
|
|
|
|
--bash <(cat completions/hyprdim.bash) \
|
|
|
|
--fish <(cat completions/hyprdim.fish) \
|
|
|
|
--zsh <(cat completions/_hyprdim)
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Automatically dim windows in Hyprland when switching between them";
|
|
|
|
homepage = "https://github.com/donovanglover/hyprdim";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ donovanglover ];
|
2023-08-06 18:13:50 +00:00
|
|
|
mainProgram = "hyprdim";
|
2023-07-26 04:42:08 +00:00
|
|
|
};
|
|
|
|
}
|