-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (50 loc) · 1.23 KB
/
wheels.yml
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: wheels
on:
workflow_dispatch:
inputs:
upload:
description: 'Upload wheels to PyPI? (0: no, 1: yes)'
required: true
default: '0'
permissions:
contents: read
checks: write
id-token: write
jobs:
wheels:
name: Build wheels
runs-on: ubuntu-latest
env:
CI_PYTHON: "3.10"
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
lfs: true
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.10"
cache: 'pip'
- name: Build
run: python .build_agent/ci.py build
- name: Copy wheels to artifact
uses: actions/upload-artifact@v3
with:
name: python-package-distributions
path: ./dist/
upload_pypi:
name: Upload wheels to PyPI
runs-on: ubuntu-latest
if: ${{ github.event.inputs.upload == '1'}}
needs: [wheels]
environment: pypi
steps:
- uses: actions/download-artifact@v3
with:
name: python-package-distributions
path: dist
- uses: pypa/[email protected]
with:
user: __token__
password: ${{ secrets.PYPI_TOKEN }}