diff --git a/Droidnix/generated/hyprland/decorations/rotating_wallpaper.nix b/Droidnix/generated/hyprland/decorations/rotating_wallpaper.nix index bbc04d473..ef1a3ea56 100644 --- a/Droidnix/generated/hyprland/decorations/rotating_wallpaper.nix +++ b/Droidnix/generated/hyprland/decorations/rotating_wallpaper.nix @@ -1,35 +1,40 @@ { + config, pkgs, - home, - flakeRoot, + lib, ... }: let - wallpaperSource = "${flakeRoot}/assets/hyprland/wallpaperstuff}"; - wallpaperTarget = "$HOME/.config/wpaperd"; + wallpaperSource = ./assets/hyprland/wallpaperstuff; in { - home.packages = [ pkgs.wpaperd ]; + # Ensure Home Manager is enabled + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; - home.file.".config/wpaperd/wallpaper.toml".source = "${wallpaperSource}/wallpaper.toml"; + home-manager.users.henrov = { + home.packages = [ pkgs.wpaperd ]; - home.file.".config/wpaperd/".source = wallpaperSource; + # Copy the entire wallpaper folder to ~/.config/wpaperd + home.file.".config/wpaperd/".source = wallpaperSource; - home.sessionVariables.DROIDNIX_PATH = "$HOME/Droidnix"; + # Optional: also copy to ~/Droidnix + home.file."Droidnix/".source = wallpaperSource; - home.systemd.user.services.wpaperd = { - description = "wpaperd wallpaper daemon"; - after = [ "graphical.target" ]; + # User systemd service to start wpaperd at login + home.systemd.user.services.wpaperd = { + enable = true; + description = "wpaperd wallpaper daemon"; + after = [ "graphical.target" ]; - serviceConfig = { - Type = "simple"; - ExecStart = "${pkgs.wpaperd}/bin/wpaperd --config ${wallpaperTarget}/wallpaper.toml"; - Restart = "on-failure"; - RestartSec = 1; + serviceConfig = { + Type = "simple"; + ExecStart = "${pkgs.wpaperd}/bin/wpaperd --config $HOME/.config/wpaperd/wallpaper.toml"; + Restart = "on-failure"; + RestartSec = 1; + WorkingDirectory = "$HOME"; + }; }; - - wantedBy = [ "default.target" ]; - enable = true; }; }