Update .gitea/workflows/release.yml
This commit is contained in:
parent
a9795bb51d
commit
b575cd92a2
@ -9,27 +9,28 @@ jobs:
|
|||||||
# name: Test
|
# name: Test
|
||||||
# uses: https://git.tainton.uk/repos/pypilot/.gitea/workflows/ci.yml@main
|
# uses: https://git.tainton.uk/repos/pypilot/.gitea/workflows/ci.yml@main
|
||||||
|
|
||||||
changelog:
|
tag:
|
||||||
name: Generate changelog
|
name: Tag release
|
||||||
uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/changelog.yaml@main
|
uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/release-with-tag.yaml@main
|
||||||
|
|
||||||
create_release:
|
create_release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: changelog
|
needs: tag
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v4.2.2
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
ref: ${{ needs.tag.outputs.tag_name }}
|
||||||
- name: Create dummy file
|
- name: Create dummy file
|
||||||
run: touch release-dummy-file.txt
|
run: echo "${{ needs.tag.outputs.changelog }}" > changelog.md
|
||||||
- name: Release
|
- name: Release
|
||||||
id: use-go-action
|
id: use-go-action
|
||||||
uses: https://gitea.com/actions/release-action@main
|
uses: https://gitea.com/actions/release-action@main
|
||||||
with:
|
with:
|
||||||
files: release-dummy-file.txt
|
files: changelog.md
|
||||||
api_key: '${{ secrets.ACTIONS_TOKEN }}'
|
api_key: '${{ secrets.ACTIONS_TOKEN }}'
|
||||||
title: ${{ needs.changelog.outputs.release_name }}
|
title: ${{ needs.tag.outputs.tag_name }}
|
||||||
body: ${{ needs.changelog.outputs.changelog }}
|
body: ${{ needs.tag.outputs.changelog }}
|
||||||
|
|
||||||
# create_release:
|
# create_release:
|
||||||
# name: Create Release
|
# name: Create Release
|
||||||
@ -41,11 +42,11 @@ jobs:
|
|||||||
print_release:
|
print_release:
|
||||||
name: Print Release
|
name: Print Release
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [changelog, create_release]
|
needs: [tag, create_release]
|
||||||
outputs:
|
outputs:
|
||||||
releaseid: ${{ steps.getid.outputs.releaseid }}
|
releaseid: ${{ steps.getid.outputs.releaseid }}
|
||||||
steps:
|
steps:
|
||||||
- run: echo "Created release ${{ needs.changelog.outputs.release_name }}."
|
- run: echo "Created release ${{ needs.tag.outputs.tag_name }}."
|
||||||
- name: Get Release ID
|
- name: Get Release ID
|
||||||
id: getid
|
id: getid
|
||||||
run: |
|
run: |
|
||||||
@ -56,7 +57,7 @@ jobs:
|
|||||||
|
|
||||||
build_whl:
|
build_whl:
|
||||||
name: Build Wheel File
|
name: Build Wheel File
|
||||||
needs: [changelog, print_release]
|
needs: [tag, print_release]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository code
|
- name: Check out repository code
|
||||||
@ -68,7 +69,7 @@ jobs:
|
|||||||
- name: Setup Poetry
|
- name: Setup Poetry
|
||||||
uses: abatilo/actions-poetry@v4
|
uses: abatilo/actions-poetry@v4
|
||||||
- name: Update pyproject.toml
|
- 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
|
- name: Install dependencies
|
||||||
run: poetry install
|
run: poetry install
|
||||||
- name: Build wheel file
|
- name: Build wheel file
|
||||||
|
Loading…
x
Reference in New Issue
Block a user