Skip to content

Workflow file for this run

name: Publish with Dynamic Versioning
on:
release:
types: [published]
permissions:
contents: write
id-token: write
jobs:
publish:
name: Publish to PyPI
runs-on: ubuntu-latest
environment: publishing
env:
PIP_CONSTRAINT: .github/workflows/constraints.txt
steps:
- name: Checkout code
uses: actions/checkout@v3.5.3
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v4.7.0
with:
python-version: "3.10"
- name: Upgrade pip
run: |
pip install pip
pip --version
- name: Install Poetry
run: |
pipx install poetry
pipx inject poetry poetry-dynamic-versioning[plugin]
poetry --version
poetry self show plugins
- name: Build
run: poetry build
- name: Upload wheel to release
uses: svenstaro/upload-release-action@v2
with:
file: dist/*.whl
tag: ${{ github.ref }}
overwrite: true
file_glob: true
- name: Publish
uses: pypa/gh-action-pypi-publish@v1.8.8