Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / applications / misc / nwg-displays / default.nix
blob18ba079088af70d67b2d9f66d220d137c95bd831
1 { lib
2 , fetchFromGitHub
3 , atk
4 , gdk-pixbuf
5 , gobject-introspection
6 , gtk-layer-shell
7 , gtk3
8 , pango
9 , python310Packages
10 , wrapGAppsHook
11 , hyprlandSupport ? false
12 , wlr-randr
15 python310Packages.buildPythonApplication rec {
16   pname = "nwg-displays";
17   version = "0.3.8";
19   src = fetchFromGitHub {
20     owner = "nwg-piotr";
21     repo = "nwg-displays";
22     rev = "v${version}";
23     hash = "sha256-9v5TQTliUEnynoGDf1UXsQ9Ym7x2gPmx4QiRJH5BId4=";
24   };
26   nativeBuildInputs = [
27     gobject-introspection
28     wrapGAppsHook
29   ];
31   buildInputs = [
32     gtk3
33   ];
35   propagatedBuildInputs = [
36     atk
37     gdk-pixbuf
38     gtk-layer-shell
39     pango
40     python310Packages.gst-python
41     python310Packages.i3ipc
42     python310Packages.pygobject3
43   ] ++ lib.optionals hyprlandSupport [
44     wlr-randr
45   ];
47   dontWrapGApps = true;
49   preFixup = ''
50     makeWrapperArgs+=("''${gappsWrapperArgs[@]}");
51   '';
53   # Upstream has no tests
54   doCheck = false;
56   meta = {
57     homepage = "https://github.com/nwg-piotr/nwg-displays";
58     description = "Output management utility for Sway and Hyprland";
59     license = lib.licenses.mit;
60     platforms = lib.platforms.linux;
61     maintainers = [ ];
62     mainProgram = "nwg-displays";
63   };