From 22a8dca789b99aa6c3e1c6ac0e5512966f3fc81c Mon Sep 17 00:00:00 2001 From: AndreasBrostrom Date: Sat, 12 Oct 2024 15:29:09 +0200 Subject: [PATCH] Fixed errors and added quick snippet --- README.md | 6 ++++++ build.py | 8 ++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 41c5046..984e2aa 100644 --- a/README.md +++ b/README.md @@ -119,3 +119,9 @@ String hooks refere to names that the script look for in order to replace a Line ### Magicwords - `$0`: Print version number provided by `--versionTag` parameter. - `$1`: Print name of the installed package selected by `--packageVersion` parameter. + +## Quick local build snippets + +```pwsh +> python build.py sandbox -p "cScripts-4.5.21-RC2.zip" -pv "4.5.21-RC2" -v "2.7.19" -y +``` \ No newline at end of file diff --git a/build.py b/build.py index b818b21..2a43a90 100644 --- a/build.py +++ b/build.py @@ -333,13 +333,13 @@ def setup_missions(temp_folder='', mission_json_data={}, count=0, use_color=Fals if changes == 'loadScreen': replace(file, - 'loadScreen = "Data\MissionLogo.paa";', + 'loadScreen = "Data\\MissionLogo.paa";', 'loadScreen = "{}";'.format(string)) continue if changes == 'overviewPicture': replace(file, - 'overviewPicture = "Data\MissionLogo.paa";', + 'overviewPicture = "Data\\MissionLogo.paa";', 'overviewPicture = "{}";'.format(string)) continue @@ -383,8 +383,8 @@ def setup_missions(temp_folder='', mission_json_data={}, count=0, use_color=Fals for func in list(reversed(string)): replace(file, - '#include "cScripts\CfgFunctions.hpp"', - '#include "cScripts\CfgFunctions.hpp"\n {}'.format(func)) + '#include "cScripts\\CfgFunctions.hpp"', + '#include "cScripts\\CfgFunctions.hpp"\n {}'.format(func)) continue if changes == 'add':