diff --git a/homeManagerModules/desktop/sway/default.nix b/homeManagerModules/desktop/sway/default.nix index d54290bb..a6ec9498 100644 --- a/homeManagerModules/desktop/sway/default.nix +++ b/homeManagerModules/desktop/sway/default.nix @@ -5,7 +5,7 @@ osConfig, ... }: { - imports = [./autoRotate.nix ./randomWallpaper.nix ./virtKeyboard.nix]; + imports = [./autoRotate.nix ./randomWallpaper.nix ./redShift.nix ./virtKeyboard.nix]; options = { alyraffauf.desktop.sway.enable = lib.mkEnableOption "Sway with extra apps."; alyraffauf.desktop.sway.randomWallpaper = lib.mkOption { @@ -18,6 +18,11 @@ default = true; type = lib.types.bool; }; + alyraffauf.desktop.sway.redShift = lib.mkOption { + description = "Whether to redshift display colors at night."; + default = true; + type = lib.types.bool; + }; alyraffauf.desktop.sway.tabletMode = { enable = lib.mkEnableOption "Tablet mode for Sway."; autoRotate = lib.mkOption { @@ -356,7 +361,6 @@ {command = "${idled}";} {command = "${notifyd}";} {command = "${lib.getExe pkgs.autotiling}";} - {command = "${lib.getExe pkgs.gammastep} -l 31.1:-94.1";} # TODO: automatic locations {command = "${pkgs.mate.mate-polkit}/libexec/polkit-mate-authentication-agent-1";} {command = ''${lib.getExe' pkgs.networkmanagerapplet "nm-applet"}'';} {command = ''${lib.getExe' pkgs.blueman "blueman-applet"}'';} diff --git a/homeManagerModules/desktop/sway/redShift.nix b/homeManagerModules/desktop/sway/redShift.nix new file mode 100644 index 00000000..d179fddd --- /dev/null +++ b/homeManagerModules/desktop/sway/redShift.nix @@ -0,0 +1,13 @@ +{ + pkgs, + lib, + config, + ... +}: { + config = lib.mkIf config.alyraffauf.desktop.sway.redShift { + home.packages = with pkgs; [gammastep]; + wayland.windowManager.sway.config.startup = [ + {command = "${lib.getExe pkgs.gammastep} -l 31.1:-94.1";} # TODO: automatic locations + ]; + }; +} \ No newline at end of file