From e6abb8e1fd7337a59e958f8c07aedb998caa4570 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20D=C3=A9saulniers?= Date: Thu, 18 Dec 2025 18:06:58 -0500 Subject: [PATCH] view_in_mpv: avoid creating --Frag files in ~/ These files created by yt-dlp are gonna spawn in the temp directory instead. --- misc/userscripts/view_in_mpv | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/misc/userscripts/view_in_mpv b/misc/userscripts/view_in_mpv index e815d4ab8..0a4516c72 100755 --- a/misc/userscripts/view_in_mpv +++ b/misc/userscripts/view_in_mpv @@ -195,7 +195,7 @@ if [[ $USE_YTDLP_FOR_DOWNLOAD == "yes" ]]; then MPV_FLAGS="$MPV_FLAGS --audio-file=$tmpdir/ytdlp_audio" IFS=" " read -r -a video_command <<< "$MPV_COMMAND $MPV_FLAGS" - "${yt_dlp_video_command[@]}" -o - "$URL" | "${video_command[@]}" --title="$(yt-dlp --cookies-from-browser chromium:~/.local/share/qutebrowser --get-title "$URL") - mpv" "$@" - + ( cd "$tmpdir" && "${yt_dlp_video_command[@]}" -o - "$URL" | "${video_command[@]}" --title="$(yt-dlp --cookies-from-browser chromium:~/.local/share/qutebrowser --get-title "$URL") - mpv" "$@" - ) ps $audio_ytdlp_pid >/dev/null && kill $audio_ytdlp_pid rm -rf "$tmpdir"