summaryrefslogtreecommitdiff
path: root/.local/bin/genwall
diff options
context:
space:
mode:
authorkrolyxon <krolyxon@tutanota.com>2022-06-01 22:55:52 +0530
committerkrolyxon <krolyxon@tutanota.com>2022-06-01 22:55:52 +0530
commit723220028038a3c6e155259e28d07e867e2d45c9 (patch)
treef07e13aaf23e820c6da71ec02466e5831502b0e2 /.local/bin/genwall
first commit
Diffstat (limited to '.local/bin/genwall')
-rwxr-xr-x.local/bin/genwall18
1 files changed, 18 insertions, 0 deletions
diff --git a/.local/bin/genwall b/.local/bin/genwall
new file mode 100755
index 0000000..ccbe75e
--- /dev/null
+++ b/.local/bin/genwall
@@ -0,0 +1,18 @@
+#!/bin/sh
+
+# Dependencies:
+# convert wal xdotool xwallpaper
+
+wall_dir=~/pix/wall
+
+if [ -z "$1" ]; then
+ wall="$(find "$wall_dir" -type f -name "*.jpg" -o -name "*.png" | shuf -n1)"
+else
+ wall="$1"
+fi
+
+convert "$wall" ~/.local/share/bg.jpg
+xwallpaper --zoom ~/.local/share/bg.jpg
+wal -c
+wal -i ~/.local/share/bg.jpg
+xdotool key super+F5