diff options
Diffstat (limited to 'bin/xgo')
-rwxr-xr-x | bin/xgo | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -11,23 +11,23 @@ for url ; do ( # If it's a YouTube video without a given start time, load it in mpv(1) case $url in - *youtube.com/watch*[?\&]t=) ;; - *youtube.com/watch*) - mpv -- "$url" && continue + *[/.]youtube.com/watch*[?\&]t=) ;; + *[/.]youtube.com/watch*) + mpv -- "$url" && exit ;; esac + # Get the MIME type data + mt=$(urlmt "$url") + # If the MIME type is an image, load it in feh(1) case $mt in image/gif) ;; image/*) - curl -- "$url" | feh - && continue + curl -- "$url" | feh - && exit ;; esac - # Get the MIME type data - mt=$(urlmt "$url") - # Otherwise, just pass it to br(1) br "$url" ) & done |