From 75d94177d4218176adc9e860cd822f313c58cd4d Mon Sep 17 00:00:00 2001 From: James Horsley Date: Mon, 11 Nov 2024 22:39:04 +0000 Subject: [PATCH] Update BuildAll.py --- scripts/BuildAll.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/scripts/BuildAll.py b/scripts/BuildAll.py index 61a8d99..ad227e4 100644 --- a/scripts/BuildAll.py +++ b/scripts/BuildAll.py @@ -32,7 +32,7 @@ def switch_game(game_code): print(f"Switching to '{colored(game_code, 'cyan')}'") subprocess.run([f"{game_code}.bat"], shell=True, check=True) -def build(version: str | None = None): +def build(version_extra: str | None = None): solution_path = VS_PROJECT_PATH / "D3D9Drv.sln" configuration = "Release" @@ -45,10 +45,10 @@ def build(version: str | None = None): "-m", f"-p:Configuration={configuration}", ] - if version: + if version_extra: # Eww stinky, just shove this in here since the rc has it anyway. with (VS_PROJECT_PATH / "gamename.h").open("a") as f: - f.write(f'\n#define VERSION_EXTRA "{version}"\n') + f.write(f'\n#define VERSION_EXTRA "{version_extra}"\n') subprocess.run(build_command, shell=True, check=True) def zip_build(build_name, version_path): @@ -72,11 +72,11 @@ def zip_build(build_name, version_path): print(f"Zipped at: {zip_file_path}") parser = argparse.ArgumentParser() -parser.add_argument("-v", "--version", required=False) +parser.add_argument("--version-extra", required=False) args = parser.parse_args() -if args.version: - version = args.version +if args.version_extra: + version = args.version_extra else: version = get_version() @@ -96,7 +96,7 @@ def zip_build(build_name, version_path): for game_code in games_codes: switch_game(game_code) - build(args.version) + build(args.version_extra) build_name = f"D3D9DrvRTX-{game_code}-{version}" zip_build(build_name, version_path) print()