[ffmpeg] Cache version data

Related: https://github.com/dasl-/pifi/issues/9
This commit is contained in:
pukkandan 2022-03-29 03:44:17 +05:30
parent 9139d2fae0
commit 8a7f68d0b1
No known key found for this signature in database
GPG key ID: 7EEE9E1E817D0A39
2 changed files with 20 additions and 24 deletions

View file

@ -2713,7 +2713,9 @@ def check_executable(exe, args=[]):
return exe
def _get_exe_version_output(exe, args):
def _get_exe_version_output(exe, args, *, to_screen=None):
if to_screen:
to_screen(f'Checking exe version: {shell_quote([exe] + args)}')
try:
# STDIN should be redirected too. On UNIX-like systems, ffmpeg triggers
# SIGTTOU if yt-dlp is run in the background.