files: play audio files with mpv no-vid and add mp3 support

Signed-off-by: Miles Alan <m@milesalan.com>
master
Anjandev Momi 4 years ago committed by Miles Alan
parent 41e2e31f6a
commit 3c65a36fd2
  1. 4
      scripts/appscripts/sxmo_files.sh

@ -3,8 +3,10 @@ EDITOR=vis
cd "/home/$USER/" || exit 1
handlefiles() {
if echo "$1" | grep -iE ".(wav|webm|mp4|ogg|opus|m4a|flac|mov|avi)$"; then
if echo "$1" | grep -iE ".(webm|ogg|mp4|mov|avi)$"; then
st -e mpv "$@"
elif echo "$1" | grep -iE ".(wav|opus|m4a|flac|mp3)$"; then
st -e mpv --vid=no -v "$@"
elif echo "$1" | grep -iE ".(jpg|png|gif)$"; then
st -e sxiv "$@"
else

Loading…
Cancel
Save