#!/bin/bash set -e [ -n "$DEBUG" ] && set -x # uri=$(eval "echo ${1}") uri="${1}" notify-send \ -i "$(iconez -n mpv | grep 32)" \ -a mpv \ 'playing' \ "${uri}" # if xap now >/dev/null 2>&1; then # xap player run --no-defaults --detached # fi # exec xap add -n "${uri}" # if ! mpv "${uri}"; then # notify-send \ # -i "$(iconez -n mpv | grep 32)" \ # -a mpv \ # -c error \ # 'failed' \ # "${uri}" # fi exec mpv "${uri}"