summaryrefslogtreecommitdiff
path: root/bin/guiscripts
diff options
context:
space:
mode:
authorRaymaekers Luca <raymaekers.luca@gmail.com>2023-05-04 10:58:52 +0200
committerRaymaekers Luca <raymaekers.luca@gmail.com>2023-05-04 10:58:52 +0200
commitfc769b5297a67ecec2690dde9b5f8ace9c9a9258 (patch)
tree50593f8b7c8089c871113239408f1a3639d203dd /bin/guiscripts
parente1f598365038e9d0f9244879d3dd31122ef02334 (diff)
use variable for resolution
Diffstat (limited to 'bin/guiscripts')
-rwxr-xr-xbin/guiscripts/newwal3
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/guiscripts/newwal b/bin/guiscripts/newwal
index 87cb9ce..427f501 100755
--- a/bin/guiscripts/newwal
+++ b/bin/guiscripts/newwal
@@ -4,13 +4,14 @@ which swaybg wal identify > /dev/null || exit 1
wall="$HOME/pics/wallpaper"
wdir="$HOME/.cache/wal"
+res="1920x1080"
test -d "$wdir" || exit 1
# if no (valid) argument, use random wallpaper
test -f "${wal:=$(realpath "$1")}" ||
wal="$(find $HOME/pics/wallpapers -type f |
xargs identify |
- grep 1920x1080 |
+ grep "$res" |
awk '{print $1}' |
shuf -n 1)"