From 5a75ed84af8e58db80f3687e8f5237dee9876485 Mon Sep 17 00:00:00 2001 From: ericmarin Date: Wed, 29 Apr 2026 21:12:05 +0200 Subject: changed wallpapermenu script --- scripts/set_random | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'scripts/set_random') diff --git a/scripts/set_random b/scripts/set_random index 52dbab4..6c4a76d 100755 --- a/scripts/set_random +++ b/scripts/set_random @@ -5,9 +5,4 @@ if test (count $argv) -lt 1; or not test -d $argv[1] exit 1 end -~/.config/scripts/set_background ( - for file in (fd . $argv[1] -t f -d 1) - if test -z $IMG; or test $file != $IMG - echo (math (random) % 1000)":$file" - end - end | sort -n | head -n 1 | cut -d ':' -f2) +~/.config/scripts/set_background "$(fd -a -t f -d 1 -E "$(basename "$IMG")" -e jpg -e png -e webp . "$argv[1]" | shuf -n1)" -- cgit v1.2.3