@rem yt-dlp helper for easier syntax. Always includes the no check certificate option, as it doesn't hurt to have it.
@echo off
setlocal
call "%~dp0_loadpaths.cmd"
set "OUTDIR=%YOUTUBE_DIR%"
if not exist "%OUTDIR%" mkdir "%OUTDIR%"
pushd "%OUTDIR%" || exit /b 1
yt-dlp.exe -f "bestaudio[ext=m4a]/bestaudio/best" -x --audio-format m4a --audio-quality 0 --no-check-certificate "%1" %2 %3 %4 %5
set "STATUS=%ERRORLEVEL%"
popd
exit /b %STATUS%
