From 0b240aca667cb23bbbc1b6d0128f314e115db3af Mon Sep 17 00:00:00 2001 From: Aly Raffauf Date: Sat, 3 Aug 2024 12:31:07 -0400 Subject: [PATCH] randomWallpaper: exit gracefully if no active monitors --- homeManagerModules/services/randomWallpaper/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/homeManagerModules/services/randomWallpaper/default.nix b/homeManagerModules/services/randomWallpaper/default.nix index cf356b1b..90e513c6 100644 --- a/homeManagerModules/services/randomWallpaper/default.nix +++ b/homeManagerModules/services/randomWallpaper/default.nix @@ -27,7 +27,8 @@ if Dir.exist?(directory) loop do active_monitors = get_outputs - + break if active_monitors.empty? + added_monitors = active_monitors - known_monitors.keys removed_monitors = known_monitors.keys - active_monitors