Tools that are search for at startup are now categorized in required and optional.

This commit is contained in:
Frédéric Tronel
2023-12-01 16:46:16 +01:00
parent 22592214bb
commit ed0494b540

View File

@@ -26,11 +26,15 @@ from shutil import copyfile, which
def checkRequiredTools():
logger = logging.getLogger(__name__)
tools = ['ffmpeg', 'ffprobe', 'mkvmerge']
for tool in tools:
required = ['ffmpeg', 'ffprobe', 'mkvmerge']
optional = ['mkvextract', 'vobusbocr']
for tool in required:
if which(tool) == None:
logger.error('Required tool: %s is missing.' % tool)
exit(-1)
for tool in optional:
if which(tool) == None:
logger.info('Optional tool: %s is missing.' % tool)
@unique