From c632b4eeaaf51a55ad00148a3836131ed5c9c599 Mon Sep 17 00:00:00 2001 From: "CanbiZ (MickLesk)" <47820557+MickLesk@users.noreply.github.com> Date: Thu, 30 Apr 2026 13:57:35 +0200 Subject: [PATCH] fix release parsing --- misc/alpine-tools.func | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/misc/alpine-tools.func b/misc/alpine-tools.func index bc9b557a..a727942b 100644 --- a/misc/alpine-tools.func +++ b/misc/alpine-tools.func @@ -324,8 +324,13 @@ fetch_and_deploy_gh_release() { } get_url() { + # Convert glob-style pattern to awk ERE: + # protect existing .* → escape literal . → convert remaining * to .* → restore .* + local _re + _re=$(printf '%s' "$pattern" | + sed 's/\.\*/__DS__/g; s/\./\\./g; s/\*/.*/g; s/__DS__/.*/g') printf '%s' "$json" | jq -r '.assets[].browser_download_url' | - awk -v p="$pattern" 'BEGIN{IGNORECASE=1} $0 ~ p {print; exit}' | + awk -v p="$_re" 'BEGIN{IGNORECASE=1} $0 ~ p {print; exit}' | tr -d '[:cntrl:]' }