-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (39 loc) · 1.09 KB
/
Copy pathpython-publish.yml
File metadata and controls
41 lines (39 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Upload Python Package
on:
push:
tags:
- "v*"
jobs:
deploy:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-latest, macos-latest, ubuntu-latest]
steps:
- uses: actions/checkout@v4.2.0
with:
submodules: true
- name: Set up Python 3.x
uses: actions/setup-python@v5.2.0
with:
python-version: 3.x
- name: Set up QEMU
if: runner.os == 'Linux'
uses: docker/setup-qemu-action@v2
with:
platforms: all
- name: Build wheels
uses: pypa/cibuildwheel@main
env:
CIBW_ARCHS_LINUX: auto aarch64 ppc64le s390x
CIBW_ARCHS_MACOS: x86_64 universal2
- name: Upload wheels
uses: actions/upload-artifact@v3
with:
path: wheelhouse/*.whl
- name: Publish to PyPI
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: pipx run twine upload --skip-existing wheelhouse/*