forked from ssc-oscar/oscar.py
-
Notifications
You must be signed in to change notification settings - Fork 1
63 lines (54 loc) · 1.85 KB
/
build-wheel.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
63
name: Build wheels
on:
push:
paths:
# only build wheels when the package code changes
- 'woc/**'
- 'setup.py'
workflow_dispatch:
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: false
jobs:
build-wheel:
name: wheels
runs-on: ubuntu-latest
# trigger the workflow only on default branch, or manually
if: ${{ github.event_name == 'workflow_dispatch' || github.ref_name == github.event.repository.default_branch }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Build wheels
uses: pypa/[email protected]
env:
CIBW_BUILD: cp3{8,9,10,11}-manylinux_x86_64
# force manylinux2014 to avoid compatibility issues on RHEL 7
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
# install required dependencies: bz2
CIBW_BEFORE_ALL: yum install -y bzip2-devel
- name: Upload wheels
uses: actions/upload-artifact@v2
with:
name: wheels
path: wheelhouse/*.whl
build-sdist:
name: sdist
runs-on: ubuntu-latest
# trigger the workflow only on default branch, or manually
if: ${{ github.event_name == 'workflow_dispatch' || github.ref_name == github.event.repository.default_branch }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Build source distribution
run: pipx run build --sdist
- name: Upload source distribution
uses: actions/upload-artifact@v2
with:
name: sdist
path: dist/*.tar.gz