2023-03-07 22:54:05 +00:00
|
|
|
name: "Release new version"
|
|
|
|
|
|
|
|
on:
|
|
|
|
# Creation of a new tag starting with v
|
|
|
|
push:
|
|
|
|
tags:
|
|
|
|
- "v*"
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
test:
|
|
|
|
uses: ./.github/workflows/test.yml
|
|
|
|
|
|
|
|
build:
|
|
|
|
uses: Steffo99/.github/.github/workflows/build-poetry.yml@main
|
|
|
|
|
|
|
|
github:
|
|
|
|
uses: Steffo99/.github/.github/workflows/release-poetry-github.yml@main
|
|
|
|
needs:
|
|
|
|
- test
|
|
|
|
- build
|
|
|
|
|
2023-11-19 03:42:20 +00:00
|
|
|
# Must be explicit due to how Trusted Publishing works on PyPI!
|
2023-03-07 22:54:05 +00:00
|
|
|
pypi:
|
2023-11-19 03:42:20 +00:00
|
|
|
name: "Publish release on PyPI"
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
2023-11-19 03:28:12 +00:00
|
|
|
permissions:
|
|
|
|
id-token: write
|
2023-11-19 03:42:20 +00:00
|
|
|
|
2023-03-07 22:54:05 +00:00
|
|
|
needs:
|
|
|
|
- test
|
|
|
|
- build
|
2023-11-19 03:42:20 +00:00
|
|
|
steps:
|
|
|
|
- name: "Download built packages from artifacts"
|
|
|
|
uses: actions/download-artifact@v3
|
|
|
|
with:
|
|
|
|
name: "Build"
|
|
|
|
path: dist/
|
|
|
|
|
|
|
|
- name: "Upload package"
|
|
|
|
uses: pypa/gh-action-pypi-publish@release/v1
|