Ability to set the test directory, the location you want the final files copied to for testing. Default: %USERPROFILE%\documents\Arma 3\<project>

This commit is contained in:
ViperMaul 2015-05-04 13:36:23 -07:00
parent 1f5e47b7c1
commit ea7a1c30eb
2 changed files with 14 additions and 0 deletions

View File

@ -49,10 +49,16 @@ module_root = P:\z\ace\addons
optionals_root = P:\z\ace\optionals
# If the command-line variable test, the addons built will be copied to the following folder.
# Default: %USERPROFILE%\documents\Arma 3\<project>
# test_dir = %USERPROFILE%\documents\Arma 3\<project>
# Directory where the built addon will be saved.
# Default: release
release_dir = P:\z\ace\release
# This string will be prefixed to all build PBO file names.
# Default: None
pbo_name_prefix = ace_

View File

@ -625,6 +625,9 @@ See the make.cfg file for additional build options.
# Release/build directory, relative to script dir
release_dir = cfg.get(make_target, "release_dir", fallback="release")
#Directory to copy the final built PBO's for a test run.
test_dir = cfg.get(make_target, "test_dir", fallback=os.path.join(os.environ["USERPROFILE"],r"documents\Arma 3"))
# Project PBO file prefix (files are renamed to prefix_name.pbo)
pbo_name_prefix = cfg.get(make_target, "pbo_name_prefix", fallback=None)
@ -1095,6 +1098,11 @@ See the make.cfg file for additional build options.
else:
a3_path = cygwin_a3path
print_yellow("Path from the registry => {}".format(a3_path))
a3_path = test_dir
print_yellow("Copying build files to {}".format(a3_path))
if os.path.exists(a3_path):
try:
shutil.rmtree(os.path.join(a3_path, project), True)