fix: install logic for unsorted files
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#!/bin/bash
|
||||
# Helldivers 2 Mod Manager v0.1.1
|
||||
# Helldivers 2 Mod Manager v0.1.3
|
||||
|
||||
# --- Globals ---
|
||||
|
||||
@@ -255,7 +255,8 @@ function mod_install() {
|
||||
done
|
||||
|
||||
declare -A patch_count # hash table - in case multiple named files are needed for 1 mod install, store the patch count
|
||||
target_files=()
|
||||
target_files=() # store the target files so we can put them in the database later
|
||||
mod_files=($(printf "%s\n" "${mod_files[@]}" | sort -t. -k1,1 -k2,2n)) # sort the mod files because with the below logic, the .stream and .gpu_resources files need to come after their respective patch files
|
||||
for file in "${mod_files[@]}"; do
|
||||
base_name=$(get_basename "$file")
|
||||
patch_prefix="$MODS_DIR/${base_name}.patch_"
|
||||
|
||||
Reference in New Issue
Block a user