|
name: Publish to PyPI |
|
|
|
on: |
|
release: |
|
types: [published] |
|
|
|
jobs: |
|
build-and-publish: |
|
runs-on: ubuntu-latest |
|
|
|
environment: |
|
name: pypi |
|
url: https://pypi.org/p/webuntis |
|
|
|
permissions: |
|
contents: read |
|
id-token: write |
|
|
|
steps: |
|
- uses: actions/checkout@v4 |
|
|
|
- uses: actions/setup-python@v5 |
|
with: |
|
python-version: "3.x" |
|
|
|
- name: Install build tools |
|
run: | |
|
python -m pip install --upgrade pip |
|
python -m pip install build |
|
|
|
- name: Build sdist and wheel |
|
run: | |
|
python -m build # erzeugt dist/* wie früher setup.py sdist bdist_wheel |
|
|
|
- name: Publish to PyPI |
|
uses: pypa/gh-action-pypi-publish@release/v1 |