From 8bb03a5c4d0d865aded70a805bad5a688ba95490 Mon Sep 17 00:00:00 2001 From: Gabriel Arazas Date: Sun, 7 Aug 2022 13:28:59 +0800 Subject: [PATCH] pop-launcher-plugin-brightness: init at 2022-08-07 --- pkgs/default.nix | 1 + .../default.nix | 30 +++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 pkgs/pop-launcher-plugin-brightness/default.nix diff --git a/pkgs/default.nix b/pkgs/default.nix index 54447bb3..e08e2a2d 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -48,6 +48,7 @@ let neuwaita-icon-theme = callPackage ./neuwaita-icon-theme { }; onagre = callPackage ./onagre { }; pop-launcher = callPackage ./pop-launcher.nix { }; + pop-launcher-plugin-brightness = callPackage ./pop-launcher-plugin-brightness { }; pop-launcher-plugin-duckduckgo-bangs = callPackage ./pop-launcher-plugin-duckduckgo-bangs.nix { }; pop-launcher-plugin-jetbrains = callPackage ./pop-launcher-plugin-jetbrains { }; diff --git a/pkgs/pop-launcher-plugin-brightness/default.nix b/pkgs/pop-launcher-plugin-brightness/default.nix new file mode 100644 index 00000000..69219baf --- /dev/null +++ b/pkgs/pop-launcher-plugin-brightness/default.nix @@ -0,0 +1,30 @@ +{ stdenv, lib, fetchFromGitHub, brightnessctl, python3Packages }: + +python3Packages.buildPythonPackage rec { + pname = "pop-launcher-plugin-brightness"; + version = "2022-08-07"; + format = "other"; + + src = fetchFromGitHub { + owner = "lucas-dclrcq"; + repo = "pop-launcher-brightness-plugin"; + rev = "d77027a7f99061f52875f60b6aae10efd3163863"; + sha256 = "sha256-5XUJx68N779MdYd1YNYi1QkBWRmgsrmXQblEciSzsiA="; + }; + + dontBuild = true; + dontConfigure = true; + + runtimeDependencies = [ brightnessctl ]; + + installPhase = '' + install -Dm644 plugin.ron -t $out/share/pop-launcher/plugins/bright + install -Dm755 bright -t $out/share/pop-launcher/plugins/bright + ''; + + meta = with lib; { + homepage = "https://github.com/lucas-dclrcq/pop-launcher-brightness-plugin"; + description = "Control your screen brightness via pop-launcher"; + # It doesn't have a license so it is unfree by default. + }; +}