Sync version with uv #3
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 distribution to PyPI | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- 'v*' | |
jobs: | |
run: | |
name: "Build and publish release" | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/v') | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
enable-cache: true | |
cache-dependency-glob: uv.lock | |
- name: Set up Python | |
run: uv python install 3.10 | |
- name: Build | |
run: uv build | |
- name: Publish | |
run: uv publish -t ${{ secrets.PYPI_TOKEN }} |