From c37800795bbcb59918c9ece0a0ef6f27f541fcd2 Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Sat, 27 Dec 2025 20:39:09 +0900 Subject: [PATCH 1/6] fix: malformed vdf path discovery --- dzgui.sh | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/dzgui.sh b/dzgui.sh index 02f5274..7c977d4 100755 --- a/dzgui.sh +++ b/dzgui.sh @@ -851,12 +851,26 @@ file_picker(){ } find_library_folder(){ local search_path="$1" - steam_path="$(python3 "$helpers_path/vdf2json.py" -i "$1/steamapps/libraryfolders.vdf" \ - | jq -r '.libraryfolders[]|select(.apps|has("221100")).path')" - if [[ ! $? -eq 0 ]] || [[ -z $steam_path ]]; then + readarray -t paths < <(python3 "$helpers_path/vdf2json.py" -i "$1/steamapps/libraryfolders.vdf" \ + | jq -r '.libraryfolders[]|select(.apps|has("221100")).path') + if [[ ! $? -eq 0 ]]; then logger WARN "Failed to parse Steam path using '$search_path'" return 1 fi + if [[ ${#paths[@]} -eq 0 ]]; then + logger WARN "No valid VDF paths in '$search_path'" + return 1 + fi + if [[ ${#paths[@]} -gt 1 ]]; then + for path in "${paths[@]}"; do + if [[ -d "$path" ]]; then + steam_path="$path" + break + fi + done + else + steam_path="${paths[0]}" + fi logger INFO "Steam path resolved to: $steam_path" } create_config(){ From 4bcf8947049e034a0d743ed9d9ab9f9ba9af9439 Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Sat, 27 Dec 2025 20:41:25 +0900 Subject: [PATCH 2/6] chore: update installscript branch --- install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install.sh b/install.sh index 13f96cc..efe9f08 100755 --- a/install.sh +++ b/install.sh @@ -11,7 +11,7 @@ fetch(){ local file="dzgui.sh" local author="aclist" local repo="dztui" - local branch="dzgui" + local branch="fix/malformed-vdf" local url local res gh_url="https://raw.githubusercontent.com/$author/$repo/$branch/$file" From b9c30b4f52deb351aee79c635363fd6da974c328 Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Sat, 27 Dec 2025 21:06:44 +0900 Subject: [PATCH 3/6] fix: encapsulate paths --- dzgui.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dzgui.sh b/dzgui.sh index 7c977d4..815345f 100755 --- a/dzgui.sh +++ b/dzgui.sh @@ -488,7 +488,7 @@ migrate_files(){ } stale_symlinks(){ local game_dir="$steam_path/steamapps/common/DayZ" - for l in $(find "$game_dir" -xtype l); do + for l in "$(find "$game_dir" -xtype l)"; do logger DEBUG "Updating stale symlink '$l'" unlink "$l" done From 0cd561b62ae35e9656b2a0a907fc371f363a87fe Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Sat, 27 Dec 2025 23:06:11 +0900 Subject: [PATCH 4/6] fix: enclose game_dir in quotes --- dzgui.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dzgui.sh b/dzgui.sh index 815345f..e3893fd 100755 --- a/dzgui.sh +++ b/dzgui.sh @@ -952,7 +952,7 @@ varcheck(){ source "$config_file" local workshop_dir="$steam_path/steamapps/workshop/content/$aid" local game_dir="$steam_path/steamapps/common/DayZ" - if [[ ! -d $steam_path ]] || [[ ! -d $game_dir ]] || [[ ! $(find $game_dir -type f) ]]; then + if [[ ! -d $steam_path ]] || [[ ! -d $game_dir ]] || [[ ! $(find "$game_dir" -type f) ]]; then logger WARN "DayZ path resolved to '$game_dir'" logger WARN "Workshop path resolved to '$workshop_dir'" qdialog "$msg2" "Yes" "Exit" From 34ee8c6645fff4c153cccb503e811284b8a14fcc Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Sat, 27 Dec 2025 23:42:49 +0900 Subject: [PATCH 5/6] fix: enclose whitespaces during setup --- .github/ISSUE_TEMPLATE/bug_report.yml | 4 ++++ .github/ISSUE_TEMPLATE/trouble.yml | 4 ++++ install.sh | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 0ad8d65..e572b50 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -5,6 +5,10 @@ labels: ["bug"] assignees: - aclist body: + - type: markdown + attributes: + value: | + ### WARNING: When posting log/config data, redact any sensitive information like API keys. - type: checkboxes id: kb attributes: diff --git a/.github/ISSUE_TEMPLATE/trouble.yml b/.github/ISSUE_TEMPLATE/trouble.yml index 1c25e69..e890c62 100644 --- a/.github/ISSUE_TEMPLATE/trouble.yml +++ b/.github/ISSUE_TEMPLATE/trouble.yml @@ -5,6 +5,10 @@ labels: ["troubleshooting"] assignees: - aclist body: + - type: markdown + attributes: + value: | + ### WARNING: When posting log/config data, redact any sensitive information like API keys. - type: dropdown id: device attributes: diff --git a/install.sh b/install.sh index efe9f08..13f96cc 100755 --- a/install.sh +++ b/install.sh @@ -11,7 +11,7 @@ fetch(){ local file="dzgui.sh" local author="aclist" local repo="dztui" - local branch="fix/malformed-vdf" + local branch="dzgui" local url local res gh_url="https://raw.githubusercontent.com/$author/$repo/$branch/$file" From 203ca0d388dced9babfefdb9247ec77ea7821afa Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Sat, 27 Dec 2025 23:44:54 +0900 Subject: [PATCH 6/6] chore: update changelog --- CHANGELOG.md | 5 +++++ dzgui.sh | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index befe399..ad04a4f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## [5.8.0] 2025-12-27 +## Fixed +- Path discovery during first-time setup when parsing filepaths with whitespaces +- First-time setup dialog continuously triggering when DayZ install path had whitespaces in it + ## [5.8.0] 2025-07-06 ## Added - Filter servers by official/unofficial status diff --git a/dzgui.sh b/dzgui.sh index e3893fd..da73642 100755 --- a/dzgui.sh +++ b/dzgui.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash set -o pipefail -version=5.8.0 +version=5.8.1 #CONSTANTS aid=221100