From acf9938819bc55b5cefca772671b95d1371a02e0 Mon Sep 17 00:00:00 2001 From: Matthew Quinn Date: Fri, 19 Jul 2024 13:03:57 +0100 Subject: [PATCH] prebuild handling of windows shell --- pre_build.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pre_build.py b/pre_build.py index da77bae419..e1dd9ae937 100644 --- a/pre_build.py +++ b/pre_build.py @@ -14,10 +14,12 @@ def build() -> None: ) exit(1) print("Building front end...") - use_shell = os.name == "nt" - subprocess.run(["yarn", "webui:install"], shell=use_shell) - subprocess.run(["yarn", "webui:build"], shell=use_shell) - + if os.name == "nt": + subprocess.run(" ".join(["yarn", "webui:install"]), shell=True) + subprocess.run(" ".join(["yarn", "webui:build"]), shell=True) + else: + subprocess.run(["yarn", "webui:install"]) + subprocess.run(["yarn", "webui:build"]) if __name__ == "__main__": build()