A lot of repairs and small changes

This commit is contained in:
Honney
2026-06-09 15:12:12 +02:00
parent 569409a9e6
commit 28c28da83a
14 changed files with 187 additions and 46 deletions
+21
View File
@@ -0,0 +1,21 @@
#!/bin/bash
# Setting wallpaper_dir
WALLPAPER_DIR="${XDG_PICTURES_DIR:-}"
# 2. If empty, use xdg-user-dir (most reliable)
if [ -z "$WALLPAPER_DIR" ]; then
if command -v xdg-user-dir >/dev/null 2>&1; then
WALLPAPER_DIR="$(xdg-user-dir PICTURES 2>/dev/null)"
fi
fi
# 3. Final fallback (hardcoded default)
if [ -z "$WALLPAPER_DIR" ] || [ ! -d "$WALLPAPER_DIR" ]; then
WALLPAPER_DIR="$HOME/Pictures"
fi
# 4. Your wallpaper subfolder
WALLPAPER_DIR="$WALLPAPER_DIR/Wallpapers"
echo $WALLPAPER_DIR