Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Python 🐍 distributions 📦 to PyPI | |
on: | |
release: | |
types: | |
- published | |
jobs: | |
build-n-publish-pypi: | |
name: Build and publish Python 🐍 distributions 📦 to PyPI | |
environment: production | |
permissions: | |
# IMPORTANT: this permission is mandatory for trusted publishing | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4.1.1 | |
- name: Set up Python3 | |
uses: actions/setup-python@v4.7.1 | |
with: | |
python-version: "3.x" | |
- name: Install packaging libraries | |
run: | | |
python -m pip install flit | |
- name: Build a binary wheel and a source tarball | |
run: | | |
python -m flit build | |
- name: Publish distribution 📦 to PyPI | |
uses: pypa/gh-action-pypi-publish@v1.8.11 |