Skip to content

Commit ee00947

Browse files
committed
Fix error if ui-compiler already exists and add message when removing old vanilla folder
1 parent c8d9181 commit ee00947

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

build.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -385,6 +385,7 @@ def save(self):
385385
print("Downloading and Extracting Vanilla assets")
386386
pathlib.Path(vanilla_archive).unlink(missing_ok=True)
387387
if os.path.exists(vanilla_folder_path):
388+
print("Attempting to remove old vanilla folder...")
388389
shutil.rmtree(vanilla_folder_path)
389390

390391
download(assets_url)
@@ -434,6 +435,8 @@ def save(self):
434435
working_cargo = True
435436
except:
436437
print("No working Rust/cargo found - download binary release of UI compiler...")
438+
if os.path.exists('ui-compiler.exe'):
439+
os.remove('ui-compiler.exe')
437440
download(
438441
"https://github.com/07th-mod/ui-editing-scripts/releases/latest/download/ui-compiler.exe"
439442
)

0 commit comments

Comments
 (0)