Skip to content

Release

Release #1

Workflow file for this run

name: Release
on:
release:
types:
- published
jobs:
release:
name: Releasing to PyPi
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- name: Check out
uses: actions/checkout@v4
- name: Set up Python
id: python
uses: actions/setup-python@v5
with:
python-version: 3.13
- name: Install workflow dependencies
run: |
pip install -r .github/workflows/requirements.txt
poetry config virtualenvs.create true
poetry config virtualenvs.in-project true
- name: Install dependencies
run: poetry install --no-interaction
- name: Set package version
run: |
version="${{ github.event.release.tag_name }}"
version="${version,,}"
version="${version#v}"
poetry version --no-interaction "${version}"
- name: Build package
run: poetry build --no-interaction
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: https://test.pypi.org/legacy/