Skip to content

Workflow file for this run

name: Upload Python Package to PyPi
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
# artifact name and pypi version are determined by the pyproject.toml
- name: Build
run: |
pip install poetry
poetry build
- name: Upload dists
uses: actions/upload-artifact@v3
with:
path: dist/
publish:
needs:
- build
runs-on: ubuntu-latest
environment: release
permissions:
id-token: write
steps:
- uses: actions/download-artifact@v3
- name: Publish package distributions to PyPI
uses: pypa/[email protected]
with:
packages_dir: artifact/