files: play audio files with mpv no-vid and add mp3 support
Signed-off-by: Miles Alan <m@milesalan.com>
This commit is contained in:
parent
41e2e31f6a
commit
3c65a36fd2
1 changed files with 3 additions and 1 deletions
|
@ -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…
Add table
Add a link
Reference in a new issue