update change-background

This commit is contained in:
cho 2023-06-18 20:27:20 +07:00
parent 2f977782b5
commit 6203f3833a
1 changed files with 2 additions and 2 deletions

View File

@ -7,8 +7,8 @@ bgaloc="${XDG_DATA_HOME:-$HOME/.local/share}/bga"
trueloc="$(readlink -f "$1")" &&
case "$(file --mime-type -b "$trueloc")" in
video/* ) ifinstalled mpvpaper && ln -sf "$trueloc" "$bgaloc" && notify-send -i "$bgaloc" "Changing wallpaper..." ;;
image/gif ) ifinstalled mpvpaper && ln -sf "$trueloc" "$bgaloc" && ln -sf "$trueloc" "$bgloc" && notify-send -i "$bgaloc" "Changing wallpaper..." ;;
video/* ) mpvpaper && ln -sf "$trueloc" "$bgaloc" && notify-send -i "$bgaloc" "Changing wallpaper..." ;;
image/gif ) mpvpaper && ln -sf "$trueloc" "$bgaloc" && ln -sf "$trueloc" "$bgloc" && notify-send -i "$bgaloc" "Changing wallpaper..." ;;
image/* ) ln -sf "$trueloc" "$bgloc" && notify-send -i "$bgloc" "Changing wallpaper..."
if [[ -f "$bgaloc" ]]; then
rm $bgaloc