dotfiles

configuration files for shell, text editor, graphical environment, etc.
git clone git://src.adamsgaard.dk/dotfiles # fast
git clone https://src.adamsgaard.dk/dotfiles.git # slow
Log | Files | Refs | README | LICENSE Back to index

commit d94b3885057c781980c8decede3cab822a84eac2
parent af08089b6d2132bb2b2be9174494e1eca7f72e9c
Author: Anders Damsgaard <anders@adamsgaard.dk>
Date:   Sun, 21 Feb 2021 08:53:45 +0100

plumb: fix order of url checking

Diffstat:
M.local/bin/plumb | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/.local/bin/plumb b/.local/bin/plumb @@ -211,10 +211,10 @@ handle_url() { port="$(printf '%s' "$t" | cut -d'|' -f5 | sed 's,\],,')" t="gopher://${host}:${port}/${type}${path}" fi - if regeximatch "$t" '\.(mp4|mkv|webm|avi|ogv|m3u|pls)$'; then - detach $prefix mpv "$t" - elif regeximatch "$t" '^radio://'; then + if regeximatch "$t" '^radio://'; then $prefix mpv --force-window=no "http${t##radio}" + elif regeximatch "$t" '\.(mp4|mkv|webm|avi|ogv|m3u|pls)$'; then + detach $prefix mpv "$t" elif regeximatch "$t" '\.(mp3|ogg|m3u|wav|opus)$'; then $prefix mplayer "$(fetch "$t")" elif regeximatch "$t" '\.(png|jpg|jpeg|tif|bmp|gif)$'; then