From f60fb4b65d53687286aefd3c27666700490a2109 Mon Sep 17 00:00:00 2001 From: GnomeZworc Date: Mon, 15 Dec 2025 13:17:17 +0100 Subject: [PATCH] add file upload third Signed-off-by: GnomeZworc --- .forgejo/workflows/build.yml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.forgejo/workflows/build.yml b/.forgejo/workflows/build.yml index eca6e23..7f4e4ff 100644 --- a/.forgejo/workflows/build.yml +++ b/.forgejo/workflows/build.yml @@ -95,6 +95,13 @@ jobs: "prerelease": true } EOF + - name: Upload asset + run: | + RELEASE_ID=$(curl -s \ + -H "Authorization: token $TOKEN" \ + https://git.g3e.fr/api/v1/repos/${{ github.repository }}/releases/tags/$TAG \ + | jq -r .id) + echo ${RELEASE_ID} ls dist | while read tmp do FILE=$(ls "./dist/${tmp}") @@ -103,12 +110,5 @@ jobs: -H "Authorization: token $TOKEN" \ -H "Content-Type: application/octet-stream" \ --data-binary @dist/${tmp}/${FILE} \ - "https://forgejo.example/api/v1/repos/${{ github.repository }}/releases/$RELEASE_ID/assets?name=${FILE}" - done - - name: Upload asset - run: | - RELEASE_ID=$(curl -s \ - -H "Authorization: token $TOKEN" \ - https://git.g3e.fr/api/v1/repos/${{ github.repository }}/releases/tags/$TAG \ - | jq -r .id) - echo ${RELEASE_ID} \ No newline at end of file + "https://git.g3e.fr/api/v1/repos/${{ github.repository }}/releases/$RELEASE_ID/assets?name=${FILE}" + done \ No newline at end of file