From 54508382725d2cf6579bb6909921d76c1de2b5a0 Mon Sep 17 00:00:00 2001 From: derped Date: Thu, 15 Jun 2023 11:04:34 +0200 Subject: [PATCH] Add pyluxafor package. --- config/etc/i3/config | 8 ++++++-- pkgs/nixpkgs.nix | 1 + pkgs/pyluxafor/default.nix | 18 ++++++++++++++++++ 3 files changed, 25 insertions(+), 2 deletions(-) create mode 100644 pkgs/pyluxafor/default.nix diff --git a/config/etc/i3/config b/config/etc/i3/config index ea3a108..6b0b078 100644 --- a/config/etc/i3/config +++ b/config/etc/i3/config @@ -44,7 +44,7 @@ bindsym $mod+Mod1+Up exec playerctl previous bindsym $mod+Shift+w sticky toggle bindsym $mod+Shift+B floating enable; border none; resize set 900 600; move position 1020 19 -### END SYSKEY BINDSYM ### +### END MEDIA BINDSYM ### ### START BINDSYM ### @@ -77,7 +77,11 @@ bindsym --release $mod+Ctrl+s exec scrot bindsym --release $mod+Ctrl+d exec "scrot --select" bindsym --release $mod+Ctrl+a exec "scrot -s '/tmp/%F_%T_$wx$h.png' -e 'xclip -selection clipboard -target image/png -i $f && rm $f'" bindsym $mod+o exec pcmanfm - +bindsym $mod+Mod1+1 exec luxa fade --speed 50 '00ff00' +bindsym $mod+Mod1+2 exec luxa fade --speed 50 'ffff00' +bindsym $mod+Mod1+3 exec luxa fade --speed 50 'ff0000' +bindsym $mod+Mod1+4 exec luxa fade --speed 50 '0000ff' +bindsym $mod+Mod1+5 exec luxa fade --speed 50 'ffffff' ### END BINDSYM ### ### START MODES ### diff --git a/pkgs/nixpkgs.nix b/pkgs/nixpkgs.nix index 65a778d..4253871 100644 --- a/pkgs/nixpkgs.nix +++ b/pkgs/nixpkgs.nix @@ -11,6 +11,7 @@ in { mpv.vaapiSupport = (lib.elem "xserver" config.machine.services); packageOverrides = { + pyluxafor = pkgs.python3Packages.callPackage ./pyluxafor {}; theme_flat-remix = callPackage ./flat-remix { }; theme_sddm_midnight = callPackage ./sddm_midnight { }; xdiskusage = callPackage ./xdiskusage { }; diff --git a/pkgs/pyluxafor/default.nix b/pkgs/pyluxafor/default.nix new file mode 100644 index 0000000..8e1da3b --- /dev/null +++ b/pkgs/pyluxafor/default.nix @@ -0,0 +1,18 @@ +{ fetchFromGitHub, buildPythonApplication, click, pyusb }: + +buildPythonApplication rec { + pname = "pyluxafor"; + version = "0.1.0"; + + src = fetchFromGitHub { + owner = "fmartingr"; + repo = pname; + rev = "858fc0a331b34d48b107193e7e0bceb077daa4d8"; + sha256 = "044czjg1xv9bz7rjw52iz3ck0c65bbmkg9r248zkv330dz345ijf"; + }; + preBuild = '' + substituteInPlace setup.py --replace '"click>=6.0,<=6.7.99",' "" + substituteInPlace setup.py --replace '"pyusb==1.0.0",' "" + ''; + propagatedBuildInputs = [ click pyusb ]; +}