From b575cd92a2100585c3614572824f4d567b52a22e Mon Sep 17 00:00:00 2001 From: Luke Tainton Date: Wed, 7 May 2025 00:15:16 +0200 Subject: [PATCH] Update .gitea/workflows/release.yml --- .gitea/workflows/release.yml | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/.gitea/workflows/release.yml b/.gitea/workflows/release.yml index c3f0bec..46f01a1 100644 --- a/.gitea/workflows/release.yml +++ b/.gitea/workflows/release.yml @@ -9,27 +9,28 @@ jobs: # name: Test # uses: https://git.tainton.uk/repos/pypilot/.gitea/workflows/ci.yml@main - changelog: - name: Generate changelog - uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/changelog.yaml@main + tag: + name: Tag release + uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/release-with-tag.yaml@main create_release: runs-on: ubuntu-latest - needs: changelog + needs: tag steps: - uses: actions/checkout@v4.2.2 with: fetch-depth: 0 + ref: ${{ needs.tag.outputs.tag_name }} - name: Create dummy file - run: touch release-dummy-file.txt + run: echo "${{ needs.tag.outputs.changelog }}" > changelog.md - name: Release id: use-go-action uses: https://gitea.com/actions/release-action@main with: - files: release-dummy-file.txt + files: changelog.md api_key: '${{ secrets.ACTIONS_TOKEN }}' - title: ${{ needs.changelog.outputs.release_name }} - body: ${{ needs.changelog.outputs.changelog }} + title: ${{ needs.tag.outputs.tag_name }} + body: ${{ needs.tag.outputs.changelog }} # create_release: # name: Create Release @@ -41,11 +42,11 @@ jobs: print_release: name: Print Release runs-on: ubuntu-latest - needs: [changelog, create_release] + needs: [tag, create_release] outputs: releaseid: ${{ steps.getid.outputs.releaseid }} steps: - - run: echo "Created release ${{ needs.changelog.outputs.release_name }}." + - run: echo "Created release ${{ needs.tag.outputs.tag_name }}." - name: Get Release ID id: getid run: | @@ -56,7 +57,7 @@ jobs: build_whl: name: Build Wheel File - needs: [changelog, print_release] + needs: [tag, print_release] runs-on: ubuntu-latest steps: - name: Check out repository code @@ -68,7 +69,7 @@ jobs: - name: Setup Poetry uses: abatilo/actions-poetry@v4 - name: Update pyproject.toml - run: ./tools/update_pyproject.sh ${{ needs.changelog.outputs.release_name }} + run: ./tools/update_pyproject.sh ${{ needs.tag.outputs.tag_name }} - name: Install dependencies run: poetry install - name: Build wheel file