From c4b963cd7e641bc594f989530f2bcc14cdee06a3 Mon Sep 17 00:00:00 2001 From: Rachel Lambda Samuelsson Date: Tue, 12 Mar 2024 14:52:40 +0100 Subject: [PATCH] empty workspace fix --- home/rachel.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/home/rachel.nix b/home/rachel.nix index 378e09c..aa3f2ae 100644 --- a/home/rachel.nix +++ b/home/rachel.nix @@ -104,6 +104,7 @@ in rec { ]}" current_display=$(wmctrl -d|awk '/*/ {print $1}') + out=$( wmctrl -lx | awk -v current_display="$current_display" '{ if ($2==current_display) { @@ -111,6 +112,10 @@ in rec { printf "%s ", "["tolower(window_title[2])"]" } }' + ) + + # workaround for clearing on empty output + printf '%s\n' "$out" ''; executable = true; };