2021-07-18 14:57:50 +00:00
|
|
|
{ lib
|
|
|
|
, buildGoModule
|
|
|
|
, cairo
|
2023-11-18 07:52:44 +00:00
|
|
|
, fetchFromGitHub
|
2021-07-18 14:57:50 +00:00
|
|
|
, gobject-introspection
|
|
|
|
, gtk-layer-shell
|
2023-11-18 07:52:44 +00:00
|
|
|
, gtk3
|
2022-01-15 15:23:11 +00:00
|
|
|
, pkg-config
|
|
|
|
, wrapGAppsHook
|
2023-11-18 07:52:44 +00:00
|
|
|
, xdg-utils
|
|
|
|
}:
|
2021-07-18 14:57:50 +00:00
|
|
|
|
2023-11-18 07:52:44 +00:00
|
|
|
let
|
2021-07-18 14:57:50 +00:00
|
|
|
pname = "nwg-drawer";
|
2024-03-24 18:55:23 +00:00
|
|
|
version = "0.4.7";
|
2021-07-18 14:57:50 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nwg-piotr";
|
2023-11-18 07:52:44 +00:00
|
|
|
repo = "nwg-drawer";
|
2021-07-18 14:57:50 +00:00
|
|
|
rev = "v${version}";
|
2024-03-24 18:55:23 +00:00
|
|
|
hash = "sha256-rBb2ArjllCBO2+9hx3f/c+uUQD1nCZzzfQGz1Wovy/0=";
|
2021-07-18 14:57:50 +00:00
|
|
|
};
|
|
|
|
|
2024-03-24 18:55:23 +00:00
|
|
|
vendorHash = "sha256-L8gdJd5cPfQrcSXLxFx6BAVWOXC8HRuk5fFQ7MsKpIc=";
|
2023-11-18 07:52:44 +00:00
|
|
|
in
|
|
|
|
buildGoModule {
|
|
|
|
inherit pname version src vendorHash;
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
gobject-introspection
|
|
|
|
pkg-config
|
|
|
|
wrapGAppsHook
|
|
|
|
];
|
2021-07-18 14:57:50 +00:00
|
|
|
|
2023-11-18 07:52:44 +00:00
|
|
|
buildInputs = [
|
|
|
|
cairo
|
|
|
|
gtk-layer-shell
|
|
|
|
gtk3
|
|
|
|
];
|
2022-01-15 15:23:11 +00:00
|
|
|
|
2023-11-18 07:52:44 +00:00
|
|
|
doCheck = false; # Too slow
|
2022-01-15 15:23:11 +00:00
|
|
|
|
|
|
|
preInstall = ''
|
|
|
|
mkdir -p $out/share/nwg-drawer
|
|
|
|
cp -r desktop-directories drawer.css $out/share/nwg-drawer
|
|
|
|
'';
|
|
|
|
|
|
|
|
preFixup = ''
|
2022-07-11 23:23:52 +00:00
|
|
|
# make xdg-open overrideable at runtime
|
2022-01-15 15:23:11 +00:00
|
|
|
gappsWrapperArgs+=(
|
2022-07-11 23:23:52 +00:00
|
|
|
--suffix PATH : ${xdg-utils}/bin
|
2022-01-15 15:23:11 +00:00
|
|
|
--prefix XDG_DATA_DIRS : $out/share
|
|
|
|
)
|
|
|
|
'';
|
2021-07-18 14:57:50 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Application drawer for sway Wayland compositor";
|
|
|
|
homepage = "https://github.com/nwg-piotr/nwg-drawer";
|
2023-11-18 07:52:44 +00:00
|
|
|
license = with lib.licenses; [ mit ];
|
2023-10-03 15:32:28 +00:00
|
|
|
mainProgram = "nwg-drawer";
|
2023-11-18 07:52:44 +00:00
|
|
|
maintainers = with lib.maintainers; [ AndersonTorres ];
|
|
|
|
platforms = with lib.platforms; linux;
|
2021-07-18 14:57:50 +00:00
|
|
|
};
|
|
|
|
}
|