Create output folder

This commit is contained in:
FzOrb 2024-12-26 12:26:34 +02:00
parent e011b11987
commit e9ac567753

4
www.py
View File

@ -39,6 +39,10 @@ def renderIndex(ct, latest):
template = environment.get_template("index.html")
render = template.render(ct=datetime.fromtimestamp(int(ct)), latest=latest, render=datetime.now().strftime("%Y-%m-%d %H:%M:%S"), sha256Linux=sha256Linux, sha256Windows=sha256Windows, sha512Linux=sha512Linux, sha512Windows=sha512Windows, md5Linux=md5Linux, md5Windows=md5Windows)
try:
os.mkdir(f'./www/output')
except FileExistsError:
print(f"Output folder already exists")
try:
os.remove("./www/output/index.html")
except FileNotFoundError: