From 36a247932e1daa76098c0a4130b8e2e08ac8e14f Mon Sep 17 00:00:00 2001 From: Artturin Date: Thu, 15 Jul 2021 01:33:10 +0300 Subject: [PATCH] nwg-wrapper: init at 0.0.1 --- .../applications/misc/nwg-wrapper/default.nix | 41 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 43 insertions(+) create mode 100644 pkgs/applications/misc/nwg-wrapper/default.nix diff --git a/pkgs/applications/misc/nwg-wrapper/default.nix b/pkgs/applications/misc/nwg-wrapper/default.nix new file mode 100644 index 000000000000..9567b051f591 --- /dev/null +++ b/pkgs/applications/misc/nwg-wrapper/default.nix @@ -0,0 +1,41 @@ +{ lib, python3Packages, fetchFromGitHub, gtk-layer-shell, gtk3, gobject-introspection, wrapGAppsHook, wlr-randr }: + +python3Packages.buildPythonPackage rec { + pname = "nwg-wrapper"; + version = "0.0.1"; + + src = fetchFromGitHub { + owner = "nwg-piotr"; + repo = pname; + rev = "v${version}"; + sha256 = "1rpkcjr0chmgsfkan88lsi476bamg9a6y7h0x9zsh60a9rdf7dl8"; + }; + + nativeBuildInputs = [ gobject-introspection wrapGAppsHook ]; + + buildInputs = [ gtk3 gtk-layer-shell ]; + + propagatedBuildInputs = with python3Packages; [ i3ipc pygobject3 ]; + + # ValueError: Namespace GtkLayerShell not available + strictDeps = false; + + # No tests + doCheck = false; + + preFixup = '' + makeWrapperArgs+=( + "''${gappsWrapperArgs[@]}" + --prefix PATH : "${lib.makeBinPath [ wlr-randr ]}" + ) + ''; + + pythonImportsCheck = [ "nwg_wrapper" ]; + + meta = with lib; { + description = "Wrapper to display a script output or a text file content on the desktop in sway or other wlroots-based compositors"; + homepage = "https://github.com/nwg-piotr/nwg-wrapper/"; + license = licenses.mit; + maintainers = with maintainers; [ artturin ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1b9f95610228..117f8bd457e1 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -25847,6 +25847,8 @@ in nwg-panel = callPackage ../applications/misc/nwg-panel { }; + nwg-wrapper = callPackage ../applications/misc/nwg-wrapper { }; + ocenaudio = callPackage ../applications/audio/ocenaudio { }; onlyoffice-bin = callPackage ../applications/office/onlyoffice-bin { };