1
- # This file is autogenerated by maturin v1.5.1
1
+ # This file is autogenerated by maturin v1.7.0
2
2
# To update, run
3
3
#
4
- # maturin generate-ci - o .github/workflows/CI.yml github
4
+ # maturin generate-ci github -m Cargo.toml --platform all - o .github/workflows/CI.yml
5
5
#
6
6
name : CI
7
7
40
40
- uses : actions/checkout@v4
41
41
- uses : actions/setup-python@v5
42
42
with :
43
- python-version : ' 3.10 '
43
+ python-version : 3.x
44
44
- name : Build wheels
45
45
uses : PyO3/maturin-action@v1
46
46
with :
54
54
name : wheels-linux-${{ matrix.platform.target }}
55
55
path : dist
56
56
57
+ musllinux :
58
+ runs-on : ${{ matrix.platform.runner }}
59
+ strategy :
60
+ matrix :
61
+ platform :
62
+ - runner : ubuntu-latest
63
+ target : x86_64
64
+ - runner : ubuntu-latest
65
+ target : x86
66
+ - runner : ubuntu-latest
67
+ target : aarch64
68
+ - runner : ubuntu-latest
69
+ target : armv7
70
+ steps :
71
+ - uses : actions/checkout@v4
72
+ - uses : actions/setup-python@v5
73
+ with :
74
+ python-version : 3.x
75
+ - name : Build wheels
76
+ uses : PyO3/maturin-action@v1
77
+ with :
78
+ target : ${{ matrix.platform.target }}
79
+ args : --release --out dist --find-interpreter
80
+ sccache : ' true'
81
+ manylinux : musllinux_1_2
82
+ - name : Upload wheels
83
+ uses : actions/upload-artifact@v4
84
+ with :
85
+ name : wheels-musllinux-${{ matrix.platform.target }}
86
+ path : dist
87
+
57
88
windows :
58
89
runs-on : ${{ matrix.platform.runner }}
59
90
strategy :
67
98
- uses : actions/checkout@v4
68
99
- uses : actions/setup-python@v5
69
100
with :
70
- python-version : ' 3.10 '
101
+ python-version : 3.x
71
102
architecture : ${{ matrix.platform.target }}
72
103
- name : Build wheels
73
104
uses : PyO3/maturin-action@v1
@@ -86,15 +117,15 @@ jobs:
86
117
strategy :
87
118
matrix :
88
119
platform :
89
- - runner : macos-latest
120
+ - runner : macos-12
90
121
target : x86_64
91
122
- runner : macos-14
92
123
target : aarch64
93
124
steps :
94
125
- uses : actions/checkout@v4
95
126
- uses : actions/setup-python@v5
96
127
with :
97
- python-version : ' 3.10 '
128
+ python-version : 3.x
98
129
- name : Build wheels
99
130
uses : PyO3/maturin-action@v1
100
131
with :
@@ -107,6 +138,43 @@ jobs:
107
138
name : wheels-macos-${{ matrix.platform.target }}
108
139
path : dist
109
140
141
+ emscripten :
142
+ runs-on : ${{ matrix.platform.runner }}
143
+ strategy :
144
+ matrix :
145
+ platform :
146
+ - runner : ubuntu-latest
147
+ target : wasm32-unknown-emscripten
148
+ steps :
149
+ - uses : actions/checkout@v4
150
+ - run : pip install pyodide-build
151
+ - name : Get Emscripten and Python version info
152
+ shell : bash
153
+ run : |
154
+ echo EMSCRIPTEN_VERSION=$(pyodide config get emscripten_version) >> $GITHUB_ENV
155
+ echo PYTHON_VERSION=$(pyodide config get python_version | cut -d '.' -f 1-2) >> $GITHUB_ENV
156
+ pip uninstall -y pyodide-build
157
+ - uses : mymindstorm/setup-emsdk@v12
158
+ with :
159
+ version : ${{ env.EMSCRIPTEN_VERSION }}
160
+ actions-cache-folder : emsdk-cache
161
+ - uses : actions/setup-python@v5
162
+ with :
163
+ python-version : ${{ env.PYTHON_VERSION }}
164
+ - run : pip install pyodide-build
165
+ - name : Build wheels
166
+ uses : PyO3/maturin-action@v1
167
+ with :
168
+ target : ${{ matrix.platform.target }}
169
+ args : --release --out dist -i ${{ env.PYTHON_VERSION }}
170
+ sccache : ' true'
171
+ rust-toolchain : nightly
172
+ - name : Upload wheels
173
+ uses : actions/upload-artifact@v4
174
+ with :
175
+ name : wasm-wheels
176
+ path : dist
177
+
110
178
sdist :
111
179
runs-on : ubuntu-latest
112
180
steps :
@@ -126,7 +194,10 @@ jobs:
126
194
name : Release
127
195
runs-on : ubuntu-latest
128
196
if : " startsWith(github.ref, 'refs/tags/')"
129
- needs : [linux, windows, macos, sdist]
197
+ needs : [linux, musllinux, windows, macos, emscripten, sdist]
198
+ permissions :
199
+ # Used to upload release artifacts
200
+ contents : write
130
201
steps :
131
202
- uses : actions/download-artifact@v4
132
203
- name : Publish to PyPI
@@ -136,3 +207,9 @@ jobs:
136
207
with :
137
208
command : upload
138
209
args : --non-interactive --skip-existing wheels-*/*
210
+ - name : Upload to GitHub Release
211
+ uses : softprops/action-gh-release@v1
212
+ with :
213
+ files : |
214
+ wasm-wheels/*.whl
215
+ prerelease : ${{ contains(github.ref, 'alpha') || contains(github.ref, 'beta') }}
0 commit comments