1
0
mirror of https://github.com/Escartem/AnimeWwise.git synced 2026-06-05 07:50:23 +08:00

prevent unwanted clearing

This commit is contained in:
Escartem
2023-10-20 14:45:13 +02:00
parent 73a5a6bec9
commit 5d23b26d81

View File

@@ -19,9 +19,13 @@ def main():
shutil.rmtree("temp") shutil.rmtree("temp")
if os.path.exists("output") and len(os.listdir("output")) > 0: if os.path.exists("output") and len(os.listdir("output")) > 0:
print("The output folder will be cleared when the program runs, press a key to continue or close this window") print("The output folder needs to be cleared, continue ? [Y/N]")
os.system("pause >nul") select = input(">")
shutil.rmtree("output") if select.lower() == "y":
shutil.rmtree("output")
else:
print("Aborting")
exit()
# Get all files to process # Get all files to process
hdiff_files = [f for f in os.listdir("audio") if f.endswith(".pck") and os.path.exists(f"patch/{f}.hdiff")] hdiff_files = [f for f in os.listdir("audio") if f.endswith(".pck") and os.path.exists(f"patch/{f}.hdiff")]