aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/wallpaper-shuffle5
1 files changed, 3 insertions, 2 deletions
diff --git a/bin/wallpaper-shuffle b/bin/wallpaper-shuffle
index 8108a10..820bfeb 100755
--- a/bin/wallpaper-shuffle
+++ b/bin/wallpaper-shuffle
@@ -2,10 +2,11 @@
let wallpapers_path = "~/wallpapers/low-poly"
swaymsg -t get_outputs |
rg name |
- split row "\n" |
+ str trim -a |
+ split row "," |
split column ":" |
get column2 |
- str trim | str trim -c "," | str trim -c '"' |
+ str trim | str trim -c '"' |
each {|output|
swaymsg $"output ($output) bg `find ($wallpapers_path) -type f | shuf -n 1` fill"
}