1{ lib, python3Packages, fetchFromGitHub, gtk-layer-shell, gtk3, gobject-introspection, wrapGAppsHook, wlr-randr }:
2
3python3Packages.buildPythonPackage rec {
4 pname = "nwg-wrapper";
5 version = "0.1.3";
6
7 src = fetchFromGitHub {
8 owner = "nwg-piotr";
9 repo = pname;
10 rev = "refs/tags/v${version}";
11 sha256 = "sha256-GKDAdjO67aedCEFHKDukQ+oPMomTPwFE/CvJu112fus=";
12 };
13
14 nativeBuildInputs = [ gobject-introspection wrapGAppsHook ];
15
16 buildInputs = [ gtk3 gtk-layer-shell ];
17
18 propagatedBuildInputs = with python3Packages; [ i3ipc pygobject3 ];
19
20 # No tests
21 doCheck = false;
22
23 preFixup = ''
24 makeWrapperArgs+=(
25 "''${gappsWrapperArgs[@]}"
26 --prefix PATH : "${lib.makeBinPath [ wlr-randr ]}"
27 )
28 '';
29
30 pythonImportsCheck = [ "nwg_wrapper" ];
31
32 meta = with lib; {
33 description = "Wrapper to display a script output or a text file content on the desktop in sway or other wlroots-based compositors";
34 homepage = "https://github.com/nwg-piotr/nwg-wrapper/";
35 license = licenses.mit;
36 maintainers = with maintainers; [ artturin ];
37 };
38}