fix: write file after wiping cache
Mirror to Codeberg / mirror-to-codeberg (push) Has been cancelled

This commit is contained in:
aclist committed 2026-01-15 05:18:13 +09:00
1 parent 317f60eddd
commit 11c29112c2
5 files changed
+22 -6

No files matched your search

+4
View File
@@ -5,6 +5,10 @@ labels: ["bug"]
assignees: assignees:
- aclist - aclist
body: body:
- type: markdown
attributes:
value: |
### WARNING: When posting log/config data, redact any sensitive information like API keys.
- type: checkboxes - type: checkboxes
id: kb id: kb
attributes: attributes:
+4
View File
@@ -5,6 +5,10 @@ labels: ["troubleshooting"]
assignees: assignees:
- aclist - aclist
body: body:
- type: markdown
attributes:
value: |
### WARNING: When posting log/config data, redact any sensitive information like API keys.
- type: dropdown - type: dropdown
id: device id: device
attributes: attributes:
+4
View File
@@ -1,5 +1,9 @@
# Changelog # Changelog
## [6.0.0-beta.20] 2026-01-14
## Fixed
- Write cache file after wiping
## [6.0.0-beta.19] 2026-01-14 ## [6.0.0-beta.19] 2026-01-14
## Fixed ## Fixed
- Steam Deck compatible script path expansion - Steam Deck compatible script path expansion
+5 -2
View File
@@ -3,7 +3,7 @@ set -o pipefail
src_path="$(readlink -e "$0")" src_path="$(readlink -e "$0")"
version=6.0.0.beta-19 version=6.0.0.beta-20
#CONSTANTS #CONSTANTS
aid=221100 aid=221100
@@ -41,6 +41,7 @@ cols_file="$state_path/$prefix.cols.json"
#CACHE FILES #CACHE FILES
coords_file="$cache_path/$prefix.coords" coords_file="$cache_path/$prefix.coords"
src_path_file="$cache_path/$prefix.src"
#legacy paths #legacy paths
hist_file="$config_path/history" hist_file="$config_path/history"
@@ -117,6 +118,7 @@ setup_state_files(){
done done
logger INFO "Wiped cache files" logger INFO "Wiped cache files"
fi fi
echo "$src_path" > "$src_path_file"
} }
print_config_vals(){ print_config_vals(){
local keys=( local keys=(
@@ -624,7 +626,7 @@ fetch_helpers_by_sum(){
[[ -f "$config_file" ]] && source "$config_file" [[ -f "$config_file" ]] && source "$config_file"
declare -A sums declare -A sums
sums=( sums=(
["funcs"]="8f44e648bde4fa50adddd3c238c6fe42" ["funcs"]="1441bb0654b398c68daa22d86275c3ce"
["query_v2.py"]="55d339ba02512ac69de288eb3be41067" ["query_v2.py"]="55d339ba02512ac69de288eb3be41067"
["servers.py"]="ed442c3aecf33f777d59dcf53650d263" ["servers.py"]="ed442c3aecf33f777d59dcf53650d263"
["ui.py"]="3d67e5e8e85a23dde1fd0e85a9be62a9" ["ui.py"]="3d67e5e8e85a23dde1fd0e85a9be62a9"
@@ -691,6 +693,7 @@ get_response_code(){
local url="$1" local url="$1"
curl -Ls -I -o /dev/null -w "%{http_code}" "$url" curl -Ls -I -o /dev/null -w "%{http_code}" "$url"
} }
fetch_ip_db(){ fetch_ip_db(){
parse_dl_url(){ parse_dl_url(){
curl -Ls "$url" \ curl -Ls "$url" \
+5 -4
View File
@@ -1,6 +1,6 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -o pipefail set -o pipefail
version="6.0.0-beta.19" version="6.0.0-beta.20"
#CONSTANTS #CONSTANTS
aid=221100 aid=221100
@@ -51,6 +51,7 @@ _cache_binary="$cache_dir/$prefix.binary"
_cache_coords="$cache_path/$prefix.coords" _cache_coords="$cache_path/$prefix.coords"
_cache_cooldown="$cache_path/$prefix.cooldown" _cache_cooldown="$cache_path/$prefix.cooldown"
_cache_lan="$cache_path/$prefix.lan" _cache_lan="$cache_path/$prefix.lan"
_cache_src_path="$cache_path/$prefix.src"
#XDG #XDG
freedesktop_path="$HOME/.local/share/applications" freedesktop_path="$HOME/.local/share/applications"
@@ -396,6 +397,7 @@ get_dist(){
logger INFO "Distance: $dist km" logger INFO "Distance: $dist km"
fi fi
} }
query_config(){ query_config(){
[[ -n $2 ]] && local key=$2 [[ -n $2 ]] && local key=$2
keys=( keys=(
@@ -421,6 +423,7 @@ query_config(){
echo "${!i}" echo "${!i}"
done done
} }
align_versions_file(){ align_versions_file(){
shift shift
local mod="$1" local mod="$1"
@@ -586,9 +589,6 @@ default_steam_path="$default_steam_path"
#Preferred Steam launch command (for Flatpak support) #Preferred Steam launch command (for Flatpak support)
preferred_client="$preferred_client" preferred_client="$preferred_client"
#DZGUI source path
src_path="$src_path"
END END
} }
format_version_url(){ format_version_url(){
@@ -642,6 +642,7 @@ download_new_version(){
return 1 return 1
fi fi
local version_url="$(format_version_url)" local version_url="$(format_version_url)"
local src_path="$(< "$_cache_src_path")"
mv "$src_path" "$src_path.old" mv "$src_path" "$src_path.old"
curl -Ls "$version_url" > "$src_path" curl -Ls "$version_url" > "$src_path"
rc=$? rc=$?