From 5736d79172c47ff84740d5720467370a560febad Mon Sep 17 00:00:00 2001 From: pukkandan Date: Fri, 16 Sep 2022 18:24:29 +0530 Subject: [PATCH] Support environment variables in `--ffmpeg-location` Closes #4938 --- yt_dlp/__init__.py | 1 + 1 file changed, 1 insertion(+) diff --git a/yt_dlp/__init__.py b/yt_dlp/__init__.py index 87d431c6e..cab2dd62f 100644 --- a/yt_dlp/__init__.py +++ b/yt_dlp/__init__.py @@ -920,6 +920,7 @@ def _real_main(argv=None): # We may need ffmpeg_location without having access to the YoutubeDL instance # See https://github.com/yt-dlp/yt-dlp/issues/2191 if opts.ffmpeg_location: + opts.ffmpeg_location = expand_path(opts.ffmpeg_location) FFmpegPostProcessor._ffmpeg_location.set(opts.ffmpeg_location) with YoutubeDL(ydl_opts) as ydl: