FFMpeg-Compressor: Rewrite some code

This commit is contained in:
OleSTEEP 2023-09-30 23:51:53 +03:00
parent a7ed37d58c
commit 657aa31148
4 changed files with 92 additions and 53 deletions

View file

@ -0,0 +1,11 @@
import tomllib
from modules import printer
try:
config = tomllib.load(open("ffmpeg-comp.toml", "rb"))
except FileNotFoundError:
try:
config = tomllib.load(open("/etc/ffmpeg-comp.toml", "rb"))
except FileNotFoundError:
printer.error("Config file not found. Please put it next to binary or in to /etc folder.")
exit()