fix(ci): absolute manifest path for jprm and stable release download URL
jprm rejects a bare file name as repository path (it checks the directory "" for existence). The asset upload answers with an /attachments/<uuid> link; the manifest now uses /releases/download/<tag>/<file> instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
d431486095
commit
333ac6f6ce
1 file changed
+6
-3
@@ -134,8 +134,10 @@ jobs:
|
|||||||
curl -fsS -X DELETE "${auth[@]}" "$api/releases/$release_id/assets/$asset_id"
|
curl -fsS -X DELETE "${auth[@]}" "$api/releases/$release_id/assets/$asset_id"
|
||||||
done
|
done
|
||||||
|
|
||||||
asset=$(curl -fsS -X POST "${auth[@]}" -F "attachment=@$ZIP" "$api/releases/$release_id/assets?name=$ASSET")
|
curl -fsS -X POST "${auth[@]}" -F "attachment=@$ZIP" "$api/releases/$release_id/assets?name=$ASSET" > /dev/null
|
||||||
url=$(printf '%s' "$asset" | json 'print(data["browser_download_url"])')
|
|
||||||
|
# The upload answers with an /attachments/<uuid> link; the release download URL is stable and readable.
|
||||||
|
url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/releases/download/$GITHUB_REF_NAME/$ASSET"
|
||||||
echo "Release-Asset: $url"
|
echo "Release-Asset: $url"
|
||||||
echo "url=$url" >> "$GITHUB_OUTPUT"
|
echo "url=$url" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
@@ -155,7 +157,8 @@ jobs:
|
|||||||
cd "$workdir"
|
cd "$workdir"
|
||||||
[ -f manifest.json ] || echo '[]' > manifest.json
|
[ -f manifest.json ] || echo '[]' > manifest.json
|
||||||
# Adds the version in front (sorted descending) and keeps older versions; MD5 of the ZIP as checksum.
|
# Adds the version in front (sorted descending) and keeps older versions; MD5 of the ZIP as checksum.
|
||||||
/opt/jprm/bin/jprm repo add manifest.json "$ZIP" --plugin-url "$URL"
|
# jprm needs an absolute path: for a bare file name it checks the directory "" and fails.
|
||||||
|
/opt/jprm/bin/jprm repo add "$workdir/manifest.json" "$ZIP" --plugin-url "$URL"
|
||||||
git add manifest.json
|
git add manifest.json
|
||||||
if git diff --cached --quiet; then
|
if git diff --cached --quiet; then
|
||||||
echo "manifest.json unverändert"
|
echo "manifest.json unverändert"
|
||||||
|
|||||||
Reference in new issue
Block a user