From f888cb15e8f1be5ca69fa5cfbaeb21bcf3b53c31 Mon Sep 17 00:00:00 2001 From: Philip Wittamore Date: Tue, 21 Oct 2025 18:05:17 +0200 Subject: update --- lynx-youtube-handler | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lynx-youtube-handler b/lynx-youtube-handler index da71719..df2dcb1 100755 --- a/lynx-youtube-handler +++ b/lynx-youtube-handler @@ -1,13 +1,13 @@ #!/usr/bin/env bash # open youtube link in mpv +# remove gopher section of URL passed +# by Lynx as mpv doesn't understand it URL=https:$(awk -F'https%3a' '{print $2}' <<< "$1") if curl --head --silent $URL > /dev/null 2>&1; then - echo "Opening Youtube video $URL" >> $HOME/.lynx-log notify-send "Launching mpv $URL" mpv $URL >/dev/null 2>&1 & else - echo "Youtube video: invalid URL $URL" >> $HOME/.lynx-log notify-send "invalid URL $URL" fi -- cgit v1.2.3