updated the xdg-https-handler script to remove resume playback when opening links

This commit is contained in:
2026-03-10 13:16:21 +01:00
parent 54609c9826
commit ae29136063

View File

@@ -1,10 +1,8 @@
#!/bin/bash
BROWSER=firefox.desktop
if [[ "$1" =~ ^https?://(www\.)?(youtube\.com/watch|youtu\.be)/ ]]; then
mpv "$1"
elif [[ "$1" =~ ^https?://(www\.)?(youtube\.com/shorts|youtu\.be)/ ]]; then
mpv "$1"
if [[ "$1" =~ ^https?://(www\.)?(youtube\.com/(watch|shorts)|youtu\.be/) ]]; then
mpv --no-resume-playback "$1"
else
gtk-launch "$BROWSER" "$1"
fi