Clean up release folder too.

This commit is contained in:
PJB3005
2017-08-09 13:43:14 +02:00
parent 23381d936f
commit 780fecff3b

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env python3 #!/usr/bin/env python3
# Packages a full release build that can be unzipped and you'll have your SS14 client and server. # Packages a full release build that can be unzipped and you'll have your SS14 client or server.
import os import os
import shutil import shutil
@@ -21,11 +21,16 @@ except ImportError:
Back = ColorDummy() Back = ColorDummy()
def main(): def main():
# Wipe out old build directory. # Wipe out old build directory. Cleans potential leftovers to make sure we have a clean build.
if os.path.exists("bin"): if os.path.exists("bin"):
print(Fore.BLUE + Style.DIM + "Clearing old build artifacts..." + Style.RESET_ALL) print(Fore.BLUE + Style.DIM + "Clearing old build artifacts (bin/)..." + Style.RESET_ALL)
shutil.rmtree("bin") shutil.rmtree("bin")
if os.path.exists("release"):
print(Fore.BLUE + Style.DIM + "Cleaning old release packages (release/)..." + Style.RESET_ALL)
shutil.rmtree("release")
os.mkdir("release")
build_windows() build_windows()
if os.path.exists("bin"): if os.path.exists("bin"):