This commit is contained in:
MickLesk
2026-01-06 20:10:34 +01:00
parent a5857b2a58
commit e06cd44584
2 changed files with 5 additions and 3 deletions

View File

@@ -1759,7 +1759,10 @@ function fetch_and_deploy_gh_release() {
if [[ "$mode" == "tarball" || "$mode" == "source" ]]; then
# GitHub API's tarball_url/zipball_url can return HTTP 300 Multiple Choices
# when a branch and tag share the same name. Use explicit refs/tags/ URL instead.
local direct_tarball_url="https://github.com/$repo/archive/refs/tags/$tag_name.tar.gz"
# URL-encode the tag_name for special characters (e.g., @papra/docker@25.12.0)
local tag_encoded
tag_encoded=$(printf '%s' "$tag_name" | jq -sRr @uri)
local direct_tarball_url="https://github.com/$repo/archive/refs/tags/$tag_encoded.tar.gz"
filename="${app_lc}-${version}.tar.gz"
curl $download_timeout -fsSL -o "$tmpdir/$filename" "$direct_tarball_url" || {