From bffbd43672ca9c3366b0e94c20fadb26d86dfdb9 Mon Sep 17 00:00:00 2001 From: erik-nilcoast <138068205+erik-nilcoast@users.noreply.github.com> Date: Sun, 16 Mar 2025 16:58:18 -0500 Subject: feat(workers): allows videoWorker to use ytdlp command line arguments specified in the config. Fixes #775 #792 (#1117) --- apps/workers/videoWorker.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'apps/workers') diff --git a/apps/workers/videoWorker.ts b/apps/workers/videoWorker.ts index 32f16f97..23ead8f8 100644 --- a/apps/workers/videoWorker.ts +++ b/apps/workers/videoWorker.ts @@ -63,7 +63,6 @@ export class VideoWorker { } function prepareYtDlpArguments(url: string, assetPath: string) { - // TODO allow custom commandline arguments? const ytDlpArguments = [url]; if (serverConfig.crawler.maxVideoDownloadSize > 0) { ytDlpArguments.push( @@ -71,6 +70,8 @@ function prepareYtDlpArguments(url: string, assetPath: string) { `best[filesize<${serverConfig.crawler.maxVideoDownloadSize}M]`, ); } + + ytDlpArguments.push(...serverConfig.crawler.ytDlpArguments); ytDlpArguments.push("-o", assetPath); ytDlpArguments.push("--no-playlist"); return ytDlpArguments; -- cgit v1.2.3-70-g09d2