diff options
Diffstat (limited to '.config/scripts')
| -rw-r--r-- | .config/scripts/wallpaper.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/.config/scripts/wallpaper.sh b/.config/scripts/wallpaper.sh index b04b8aa..3206102 100644 --- a/.config/scripts/wallpaper.sh +++ b/.config/scripts/wallpaper.sh @@ -1,15 +1,15 @@ #!/bin/bash -WALL_DIR="$HOME/.config/wallpaper" -CACHE_PATH="$HOME/.cache/current_wallpaper.png" +WALL_DIR="$HOME/.config/wallpaper/" +CACHE_PATH="$HOME/.cache/wallpaper.*" selected=$(echo -e "random\n$(ls "$WALL_DIR")" | fuzzel -d -p "> ") [[ -z "$selected" ]] && exit if [ "$selected" = "random" ]; then - current_wall=$(basename "$(readlink -f "$CACHE_PATH")") - selected=$(ls "$WALL_DIR" | grep -v "$current_wall" | shuf -n 1) + wall=$(basename "$(readlink -f "$CACHE_PATH")") + selected=$(ls "$WALL_DIR" | grep -v "$wall" | shuf -n 1) fi FULL_PATH="$WALL_DIR/$selected" |
