From 28d4cb1daafbff9f4f84173d2806c9c17d7712e9 Mon Sep 17 00:00:00 2001 From: Mohamed Youssef Date: Sun, 2 Aug 2026 09:27:52 +0300 Subject: [PATCH] update Workflows --- .gitea/workflows/release.yml | 40 ++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/.gitea/workflows/release.yml b/.gitea/workflows/release.yml index dcce75a..9ce94cb 100644 --- a/.gitea/workflows/release.yml +++ b/.gitea/workflows/release.yml @@ -113,26 +113,26 @@ jobs: cd build zip -r "../${SLUG}-${{ steps.meta.outputs.version }}.zip" "${SLUG}" - - name: Debug - check RELEASE_TOKEN is set + - name: Install tea CLI + run: | + TEA_VERSION="0.14.2" + curl -fL -o /usr/local/bin/tea \ + "https://gitea.com/gitea/tea/releases/download/v${TEA_VERSION}/tea-${TEA_VERSION}-linux-amd64" + chmod +x /usr/local/bin/tea + tea --version + + - name: Create Gitea Release (tea CLI) if: steps.check.outputs.should_release == 'true' run: | - if [ -z "${{ secrets.RELEASE_TOKEN }}" ]; then - echo "::error::RELEASE_TOKEN secret is empty or not set." - exit 1 - else - echo "RELEASE_TOKEN is set (length: ${#TOKEN})." - fi - env: - TOKEN: ${{ secrets.RELEASE_TOKEN }} + ZIP="${{ steps.meta.outputs.slug }}-${{ steps.meta.outputs.version }}.zip" - - name: Create Gitea Release - if: steps.check.outputs.should_release == 'true' - uses: https://github.com/akkuman/gitea-release-action@v1 - env: - NODE_OPTIONS: "--experimental-fetch" # only needed if runner's node < 18 - with: - files: |- - ${{ steps.meta.outputs.slug }}-${{ steps.meta.outputs.version }}.zip - tag_name: "${{ steps.check.outputs.tag }}" - name: "${{ steps.meta.outputs.name }} ${{ steps.meta.outputs.version }}" - token: "${{ secrets.RELEASE_TOKEN }}" \ No newline at end of file + tea login add \ + --name ci \ + --url "${{ gitea.server_url }}" \ + --token "${{ secrets.RELEASE_TOKEN }}" + + tea releases create \ + --repo "${{ gitea.repository }}" \ + --tag "${{ steps.check.outputs.tag }}" \ + --title "${{ steps.meta.outputs.name }} ${{ steps.meta.outputs.version }}" \ + --asset "${ZIP}" \ No newline at end of file