Skip to content

Merge pull request #1160 from ToFuProject/devel #36

Merge pull request #1160 from ToFuProject/devel

Merge pull request #1160 from ToFuProject/devel #36

name: uv publish bdist to PyPI
on:
release:
types:
[created]
push:
branches:
- master
- deploy-test
jobs:
pypi:
name: Publish bdist to Pypi
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest] # windows-latest, macOS-latest]
python-version: ['3.9', '3.10', '3.11']
#exclude:
#- python-version: ['3.11']
#os: windows-latest
runs-on: ${{ matrix.os }}
steps:
# git checkout
- name: git checkout
uses: actions/checkout@v5
with:
# https://github.com/marketplace/actions/checkout#usage
fetch-depth: 0 # to fetch all history from all branches
fetch-tags: true
# Install uv
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
python-version: ${{ matrix.python-version }}
# Build dist
- name: Build the project
run: |
rm dist/*
uv build
rm dist/*.tar.gz
- name: Publish bdist to PyPI
env:
UV_PUBLISH_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
run: |
uv publish