1
0
Fork 0
mirror of https://github.com/aclist/dztui.git synced 2025-04-05 12:03:00 +02:00

Fix array bug

This commit is contained in:
aclist 2022-06-09 00:25:08 +09:00 committed by GitHub
parent e0276d4f95
commit 05cee7b70d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
set -eo pipefail set -eo pipefail
version=0.3.0 version=0.3.1
release_url="https://raw.githubusercontent.com/aclist/dztui/main/dztui.sh" release_url="https://raw.githubusercontent.com/aclist/dztui/main/dztui.sh"
aid=221100 aid=221100
game="dayz" game="dayz"
@ -136,7 +136,7 @@ table(){
done done
} }
concat_mods(){ concat_mods(){
readarray -t serv <<< "$remote_mods" readarray -t serv <<< "$(server_modlist)"
for i in "${serv[@]}"; do for i in "${serv[@]}"; do
id=$(awk -F"= " '/publishedid/ {print $2}' "$workshop_dir"/$i/meta.cpp | awk -F\; '{print $1}') id=$(awk -F"= " '/publishedid/ {print $2}' "$workshop_dir"/$i/meta.cpp | awk -F\; '{print $1}')
mod=$(awk -F\" '/name/ {print $2}' "$workshop_dir"/$i/meta.cpp | sed -E 's/[^[:alpha:]0-9]+/_/g; s/^_|_$//g') mod=$(awk -F\" '/name/ {print $2}' "$workshop_dir"/$i/meta.cpp | sed -E 's/[^[:alpha:]0-9]+/_/g; s/^_|_$//g')