aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2022-05-09 00:55:14 +1200
committerTom Ryder <tom@sanctum.geek.nz>2022-05-09 00:56:26 +1200
commit6ee60e405a1421b31d1a402270176514b1eae1c1 (patch)
tree1ef67595b827b509938798c37c8583ff4b14d7f5
parentPrevent mpv output junk in .xsession-errors (diff)
downloaddotfiles-6ee60e405a1421b31d1a402270176514b1eae1c1.tar.gz
dotfiles-6ee60e405a1421b31d1a402270176514b1eae1c1.zip
Open GIFs in mpv
-rw-r--r--bin/xgo.sh9
1 files changed, 5 insertions, 4 deletions
diff --git a/bin/xgo.sh b/bin/xgo.sh
index c888622d..c59409a5 100644
--- a/bin/xgo.sh
+++ b/bin/xgo.sh
@@ -59,14 +59,15 @@ for url do (
)
;;
- # Open audio and video in mpv(1); force a window even for audio so I
- # can control it
+ # Open audio and video in mpv(1)
(audio/*|video/*)
exec mpv --force-window --no-terminal -- "$url"
;;
- # If the MIME type is an image that is not a GIF, load it in feh(1)
- (image/gif) ;;
+ # Open GIFs with a looping mpv(1), and all other images with feh(1)
+ (image/gif)
+ exec mpv --force-window --loop=inf --no-terminal -- "$url"
+ ;;
(image/*)
exec curl -- "$url" | feh -
;;