-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (53 loc) · 1.53 KB
/
build.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: Build
on: [push, pull_request]
jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }} for ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, windows-2019, macos-12]
arch: [auto]
include:
- os: ubuntu-20.04
arch: aarch64
steps:
- uses: actions/checkout@v4
- name: Set up QEMU
if: ${{ matrix.arch == 'aarch64' }}
uses: docker/setup-qemu-action@v3
- name: Build wheels
uses: pypa/[email protected]
env:
CIBW_ARCHS_LINUX: ${{ matrix.arch }}
CIBW_BEFORE_BUILD: "pip install -r ./requirements.txt"
# ...
# with:
# package-dir: .
# output-dir: wheelhouse
# config-file: {package}/pyproject.toml
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl
build_sdist:
name: Build sdist
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel mypy
pip install -U -r requirements.txt
- name: Build distributions
run: |
python ./setup.py sdist
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
path: dist/*.tar.gz