|
|
@ -3,9 +3,14 @@ EDITOR=vis |
|
|
|
cd "/home/$USER/" || exit 1 |
|
|
|
cd "/home/$USER/" || exit 1 |
|
|
|
|
|
|
|
|
|
|
|
handlefiles() { |
|
|
|
handlefiles() { |
|
|
|
echo "$1" | grep -iE ".(wav|webm|mp4|ogg|opus|m4a|flac|mov|avi)$" && st -e mpv "$@" && exit |
|
|
|
if echo "$1" | grep -iE ".(wav|webm|mp4|ogg|opus|m4a|flac|mov|avi)$"; then |
|
|
|
echo "$1" | grep -iE ".(jpg|png|gif)$" && st -e sxiv "$@" && exit |
|
|
|
st -e mpv "$@" |
|
|
|
st -e sh -ic "$EDITOR $*" && exit |
|
|
|
elif echo "$1" | grep -iE ".(jpg|png|gif)$"; then |
|
|
|
|
|
|
|
st -e sxiv "$@" |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
st -e sh -ic "$EDITOR $*" |
|
|
|
|
|
|
|
fi |
|
|
|
|
|
|
|
exit 0 |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
while true; do |
|
|
|
while true; do |
|
|
|