diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..3873bdb --- /dev/null +++ b/.editorconfig @@ -0,0 +1,9 @@ +root = true + +[*] +end_of_line = lf +insert_final_newline = true +charset = utf-8 +indent_style = space +indent_size = 4 +trim_trailing_whitespace = true \ No newline at end of file diff --git a/cavAuxModList_dev.json b/cavAuxModList_dev.json new file mode 100644 index 0000000..39eea39 --- /dev/null +++ b/cavAuxModList_dev.json @@ -0,0 +1,11 @@ +{ + "workshop": { + "2021778690": { + "name": "TFTW Female Characters", + "url": "https://steamcommunity.com/sharedfiles/filedetails/?id=2021778690", + "requireResigning": false, + "License": "License permits", + "comment": "Adds female faces." + } + } +} diff --git a/scripts/assemble.py b/scripts/assemble.py old mode 100644 new mode 100755 index 306bcb5..63e3591 --- a/scripts/assemble.py +++ b/scripts/assemble.py @@ -99,6 +99,17 @@ def get_commit_id(): def download_mod_files(complete_mod_list, STEAM_LOGIN, STEAM_PASS, verbose=False): + # Check if password and username is set + if STEAM_LOGIN == "" and STEAM_PASS == "": + print("Warning: No steamcmd username and password provided skipping download") + return + elif STEAM_LOGIN == "": + print("Warning: No steamcmd username provided skipping download") + return + elif STEAM_PASS == "": + print("Warning: No steamcmd password provided skipping download") + return + login_cmd = [ STEAMCMD, '+force_install_dir', WORKDIR, @@ -143,6 +154,7 @@ def main(): parser.add_argument('-p', '--password', type=str) parser.add_argument('-C', '--config', type=str) parser.add_argument('-s', '--commit', type=str) + parser.add_argument('-d', '--data', type=str) parser.add_argument('--verbose', action='store_true') parser.add_argument('--dryrun', action='store_false') @@ -172,8 +184,10 @@ def main(): # Checking required tools check_required_tools() + providerFile = args.data if args.data else "cavAuxModList.json" + # Obtain list - modListPath = os.path.join(PROJECTROOT, "cavAuxModList.json") + modListPath = os.path.join(PROJECTROOT, providerFile) try: modListFile = open(modListPath) except FileNotFoundError: @@ -224,7 +238,7 @@ def main(): allModsExist=True for expectedMod in modListDict['workshop'].keys(): if not expectedMod in os.listdir(WORKSHOPOUT): - print(f"[Error] {modListDict['workshop'][downloadedMod]['name']} [{downloadedMod}] does not exist or have not download properly") + print(f"[Error] {modListDict['workshop'][expectedMod]['name']} [{expectedMod}] does not exist or have not download properly") allModsExist=False else: print(f"Mod {modListDict['workshop'][expectedMod]['name']} [{expectedMod}] successfully downloaded...") if args.verbose else ""