From 49f517b6a47c277ecb8dc91c4036ea0f59a03f0d Mon Sep 17 00:00:00 2001 From: Yannik <80621863+vaporvee@users.noreply.github.com> Date: Sat, 22 Apr 2023 21:29:47 +0200 Subject: [PATCH] fix build.py --- build.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/build.py b/build.py index e97f610..7cb59da 100644 --- a/build.py +++ b/build.py @@ -1,17 +1,18 @@ import os import sys -yes = {'yes','y', 'ye', ''} -no = {'no','n'} +yes = {'yes', 'y', 'ye', ''} +no = {'no', 'n'} -if sys.argv[1]: +if len(sys.argv) > 1: choice = sys.argv[1].removeprefix("-") else: - sys.stdout.write("Do you want to open only the built project instead of the Godot Editor after building? ([y]es/[n]o): ") + sys.stdout.write( + "Do you want to open only the built project instead of the Godot Editor after building? ([y]es/[n]o): ") choice = input().lower() if choice in yes: - os.system("scons && cd project && godot") + os.system("scons && cd project && godot") elif choice in no: - os.system("scons && godot project\project.godot") + os.system("scons && godot project\project.godot") else: - sys.stdout.write("Please respond with 'yes' or 'no'") \ No newline at end of file + sys.stdout.write("Please respond with 'yes' or 'no'")