-
-
Notifications
You must be signed in to change notification settings - Fork 20
99 lines (85 loc) · 2.63 KB
/
build_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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
name: Build and Publish GH+PyPi
on:
workflow_dispatch:
branches:
- master
jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04, windows-2019, macos-11]
steps:
- name: GitHub Checkout
uses: actions/checkout@v4
- name: Build wheels
uses: pypa/[email protected]
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl
build_wheels_raspberry:
name: Build wheels for Raspberry Pi
runs-on: ubuntu-latest
steps:
- name: GitHub Checkout
uses: actions/checkout@v4
- name: Set up QEMU
run: |
sudo apt-get update
sudo apt-get install -y qemu qemu-user-static qemu-user binfmt-support
docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
- name: Build wheels with QEMU
uses: pypa/[email protected]
env:
CIBW_ARCHS_LINUX: "arm64 armv7l"
CIBW_MANYLINUX_AARCH64_IMAGE: "quay.io/pypa/manylinux2014_aarch64"
CIBW_MANYLINUX_ARMV7L_IMAGE: "quay.io/pypa/manylinux2014_armv7l"
- name: Upload Raspberry Pi Wheels
uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl
build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- name: GitHub Checkout
uses: actions/checkout@v4
- name: Build sdist
run: pipx run build --sdist
- name: Upload Artifacts
uses: actions/upload-artifact@v3
with:
path: dist/*.tar.gz
Release:
needs: [build_wheels, build_wheels_raspberry, build_sdist]
runs-on: ubuntu-latest
environment: pypi
permissions:
contents: write
discussions: write
id-token: write
steps:
- name: Download Artifacts
uses: actions/download-artifact@v3
with:
name: artifact
path: dist
- name: Create GitHub Release
uses: softprops/action-gh-release@v1
with:
body: |
Please read the [CHANGELOG](https://github.com/LUCIT-Systems-and-Development/unicorn-fy/blob/master/CHANGELOG.md) for further information.
discussion_category_name: releases
draft: false
files: |
dist/*.tar.gz
dist/*.whl
generate_release_notes: true
name: unicorn-fy
prerelease: false
tag_name: 0.13.1
token: ${{ secrets.GITHUB_TOKEN }}
- name: Create PyPi Release
uses: pypa/gh-action-pypi-publish@release/v1