From 907a001a3ac84de29922b4b782975bbbd178a8e4 Mon Sep 17 00:00:00 2001 From: get Date: Mon, 15 Apr 2024 13:18:01 +0200 Subject: [PATCH] Added hyprland wallpaper --- hosts/lars/dyonisos/configuration.nix | 1 + hosts/lars/hyprland.nix | 7 +++++++ hosts/lars/programs.nix | 1 + 3 files changed, 9 insertions(+) diff --git a/hosts/lars/dyonisos/configuration.nix b/hosts/lars/dyonisos/configuration.nix index e41888a..3142fa9 100644 --- a/hosts/lars/dyonisos/configuration.nix +++ b/hosts/lars/dyonisos/configuration.nix @@ -10,6 +10,7 @@ hyprland = { enable = true; monitor = [",preferred,auto,2"]; + wallpaper = "wallpaper/nix.png"; }; }; } diff --git a/hosts/lars/hyprland.nix b/hosts/lars/hyprland.nix index 41168ce..1299063 100644 --- a/hosts/lars/hyprland.nix +++ b/hosts/lars/hyprland.nix @@ -2,6 +2,7 @@ with lib; let username = config.modules.other.system.username; cfg = config.modules.hyprland; + gitPath = config.modules.other.system.gitPath; in { imports = [ ./waybar.nix @@ -20,6 +21,11 @@ in { default = {}; type = types.attrs; }; + wallpaper = mkOption { + description = "wallpaper relative from assets"; + default = ""; + type = types.str; + }; }; config = mkIf cfg.enable { @@ -84,6 +90,7 @@ in { exec-once = [ "waybar" + "swww init & swww img ${gitPath}/${cfg.wallpaper}" ]; bind = [ diff --git a/hosts/lars/programs.nix b/hosts/lars/programs.nix index ed7673c..a730582 100644 --- a/hosts/lars/programs.nix +++ b/hosts/lars/programs.nix @@ -57,6 +57,7 @@ in { xdg-utils # xdg-mime script webcord element-desktop + swww ]; }; }