diff --git a/home/environments/hyprland/konawall.nix b/home/environments/hyprland/konawall.nix index aa13bba4..ad255616 100644 --- a/home/environments/hyprland/konawall.nix +++ b/home/environments/hyprland/konawall.nix @@ -5,61 +5,24 @@ ... }: let konawallConfig = { - interval = 30 * 60; - rotate = true; - source = "e621"; - tags = [ - "-rating:s" - "-male/male" - "-five_nights_at_freddy's" - #"touhou" - "-male" - "-large_breasts" - "-scalie" - #"-my_little_pony" - "-sonic_the_hedgehog" - "-amputee" - "-inflation" - "-pool_toy" - "-cuckold" - "-gore" - "-human" - "-animated" - "-hyper" - "-death" - "ratio:>=1.3" - "-muscular_male" - "-model_sheet" - "score:>=100" - "width:>=1500" - ]; - logging = { - file = "INFO"; - console = "DEBUG"; - }; - }; in { sops.secrets.konawall-py-env = { sopsFile = ./konawall.yaml; }; - home.packages = [ - inputs.konawall-py.packages.${pkgs.system}.konawall-py - ]; - xdg.configFile = { - "konawall/config.toml".source = (pkgs.formats.toml {}).generate "konawall-config" konawallConfig; - }; - systemd.user.services.konawall-py = { - Unit = { - Description = "konawall-py"; - X-Restart-Triggers = [(toString config.xdg.configFile."konawall/config.toml".source)]; - After = ["graphical-session.target" "network-online.target"]; + programs.konawall-py = { + enable = true; + settings = { + interval = 30 * 60; + rotate = true; + tags = [ + "score:>=100" + "width:>=1500" + ]; + logging = { + file = "INFO"; + console = "DEBUG"; + }; }; - Service = { - ExecStart = "${inputs.konawall-py.packages.${pkgs.system}.konawall-py}/bin/konawall"; - Restart = "on-failure"; - RestartSec = "1s"; - EnvironmentFile = config.sops.secrets.konawall-py-env.path; - }; - Install = {WantedBy = ["graphical-session.target"];}; + environmentFile = sops.secrets.konawall-py-env.pathg; }; } diff --git a/home/environments/niri/konawall.nix b/home/environments/niri/konawall.nix index aa13bba4..383273d1 100644 --- a/home/environments/niri/konawall.nix +++ b/home/environments/niri/konawall.nix @@ -1,65 +1,24 @@ { - inputs, - pkgs, config, ... -}: let - konawallConfig = { - interval = 30 * 60; - rotate = true; - source = "e621"; - tags = [ - "-rating:s" - "-male/male" - "-five_nights_at_freddy's" - #"touhou" - "-male" - "-large_breasts" - "-scalie" - #"-my_little_pony" - "-sonic_the_hedgehog" - "-amputee" - "-inflation" - "-pool_toy" - "-cuckold" - "-gore" - "-human" - "-animated" - "-hyper" - "-death" - "ratio:>=1.3" - "-muscular_male" - "-model_sheet" - "score:>=100" - "width:>=1500" - ]; - logging = { - file = "INFO"; - console = "DEBUG"; - }; - }; -in { +}: { sops.secrets.konawall-py-env = { sopsFile = ./konawall.yaml; }; - home.packages = [ - inputs.konawall-py.packages.${pkgs.system}.konawall-py - ]; - xdg.configFile = { - "konawall/config.toml".source = (pkgs.formats.toml {}).generate "konawall-config" konawallConfig; - }; - systemd.user.services.konawall-py = { - Unit = { - Description = "konawall-py"; - X-Restart-Triggers = [(toString config.xdg.configFile."konawall/config.toml".source)]; - After = ["graphical-session.target" "network-online.target"]; + programs.konawall-py = { + enable = true; + settings = { + interval = 30 * 60; + rotate = true; + tags = [ + "score:>=100" + "width:>=1500" + ]; + logging = { + file = "INFO"; + console = "DEBUG"; + }; }; - Service = { - ExecStart = "${inputs.konawall-py.packages.${pkgs.system}.konawall-py}/bin/konawall"; - Restart = "on-failure"; - RestartSec = "1s"; - EnvironmentFile = config.sops.secrets.konawall-py-env.path; - }; - Install = {WantedBy = ["graphical-session.target"];}; + environmentFile = config.sops.secrets.konawall-py-env.path; }; } diff --git a/modules/home/konawall.nix b/modules/home/konawall.nix new file mode 100644 index 00000000..be358139 --- /dev/null +++ b/modules/home/konawall.nix @@ -0,0 +1,42 @@ +{ inputs, lib, pkgs, config, ... }: let + inherit (lib.options) mkOption mkEnableOption mkPackageOption; + inherit (lib.types) submodule path nullOr; + inherit (lib.modules) mkIf; + cfg = config.programs.konawall-py; +in { + options.programs.konawall-py = { + enable = mkEnableOption "konawall, the wallpaper manager"; + package = mkPackageOption inputs.konawall-py.packages.${pkgs.system} "konawall-py" {}; + settings = mkOption { + type = submodule { + freeformType = (pkgs.formats.toml {}).type; + }; + default = {}; + }; + environmentFile = mkOption { + type = nullOr path; + default = null; + }; + }; + config = mkIf cfg.enable { + home.packages = [ + cfg.package + ]; + xdg.configFile."konawall/config.toml".source = (pkgs.formats.toml {}).generate "konawall-config" cfg.settings; + + systemd.user.services.konawall-py = { + Unit = { + Description = "konawall-py"; + X-Restart-Triggers = [(toString config.xdg.configFile."konawall/config.toml".source)]; + After = ["graphical-session.target" "network-online.target"]; + }; + Service = { + ExecStart = "${cfg.package}/bin/konawall"; + Restart = "on-failure"; + RestartSec = "1s"; + EnvironmentFile = cfg.environmentFile; + }; + Install = {WantedBy = ["graphical-session.target"];}; + }; + }; +} diff --git a/nixos/hardware/framework/fingerprint.nix b/nixos/hardware/framework/fingerprint.nix index c33118c6..810157e7 100644 --- a/nixos/hardware/framework/fingerprint.nix +++ b/nixos/hardware/framework/fingerprint.nix @@ -11,6 +11,6 @@ }) .fwupd; }; - fprintd.enable = true; + fprintd.enable = false; }; } diff --git a/systems/goliath.nix b/systems/goliath.nix index 080c5227..fc6c7b28 100644 --- a/systems/goliath.nix +++ b/systems/goliath.nix @@ -64,7 +64,50 @@ _: let common-gpu-nvidia-nonprime ]); - home-manager.users.kat.imports = + home-manager.users.kat = { + programs = { + konawall-py.settings = { + source = "e621"; + tags = [ + "-rating:s" + "-male/male" + "-five_nights_at_freddy's" + #"touhou" + "-male" + "-large_breasts" + "-scalie" + #"-my_little_pony" + "-sonic_the_hedgehog" + "-amputee" + "-inflation" + "-pool_toy" + "-cuckold" + "-gore" + "-human" + "-animated" + "-hyper" + "-death" + "ratio:>=1.3" + "-muscular_male" + "-model_sheet" + ]; + }; + niri.settings = { + outputs = { + "LG Electronics LG Ultra HD 0x0001AC91" = { + scale = 1.25; + }; + }; + environment = { + NVD_BACKEND = "direct"; + ELECTRON_OZONE_PLATFORM_HINT = "auto"; + LIBVA_DRIVER_NAME = "nvidia"; + NIXOS_OZONE_WL = "1"; + QT_QTA_PLATFORM = "wayland;xcb"; + }; + }; + }; + imports = (with tree.home.profiles; [ graphical ]) @@ -72,24 +115,10 @@ _: let #hyprland niri ]); + }; networking.hostId = "c3b94e85"; - home-manager.users.kat.programs.niri.settings = { - outputs = { - "LG Electronics LG Ultra HD 0x0001AC91" = { - scale = 1.25; - }; - }; - environment = { - NVD_BACKEND = "direct"; - ELECTRON_OZONE_PLATFORM_HINT = "auto"; - LIBVA_DRIVER_NAME = "nvidia"; - NIXOS_OZONE_WL = "1"; - QT_QTA_PLATFORM = "wayland;xcb"; - }; - }; - programs.ssh.extraConfig = '' Host daiyousei-build HostName 140.238.156.121 diff --git a/systems/koishi.nix b/systems/koishi.nix index deed1d78..5e6c8b68 100644 --- a/systems/koishi.nix +++ b/systems/koishi.nix @@ -61,13 +61,28 @@ _: let niri ]); config = { - home-manager.users.kat.imports = + home-manager.users.kat = { + programs = { + konawall-py.settings = { + source = "konachan"; + tags = [ + "-rating:s" + ]; + }; + niri.settings = { + outputs = { + "eDP-1".scale = 1.25; + }; + }; + }; + imports = (with tree.home.profiles; [ graphical ]) ++ (with tree.home.environments; [ niri ]); + }; fileSystems = datasetEntries