Skip to content

Upload Python Package to PyPI #13

Upload Python Package to PyPI

Upload Python Package to PyPI #13

Workflow file for this run

name: Upload Python Package to PyPI
on:
release:
types: [created]
permissions:
contents: read
packages: read
jobs:
build-and-publish:
runs-on: ubuntu-latest
environment: release
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Install build dependencies
run: |
python -m pip install --upgrade pip
pip install build
- name: Build the package
run: python -m build
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_TOKEN }}