-
Notifications
You must be signed in to change notification settings - Fork 0
236 lines (206 loc) · 5.98 KB
/
ci.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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
name: CI
on:
push:
branches: '*'
tags: v*
pull_request:
branches:
- master
schedule:
- cron: 0 0 * * *
env:
MACOSX_DEPLOYMENT_TARGET: 10.12
defaults:
run:
shell: bash
jobs:
test:
name: ${{ matrix.arch }}-${{ matrix.data.os.target }}${{ matrix.data.os.version }} ${{ matrix.compiler }}
runs-on: ${{ matrix.data.os.host }}
continue-on-error: ${{ matrix.nightly == 'nightly' }}
env:
LIME_ARCH: ${{ matrix.arch }}
LIME_COMPILER: ${{ matrix.compiler }}
LIME_CROSS_COMPILE: ${{ matrix.data.cross_compile }}
LIME_OS: ${{ matrix.data.os.target }}
LIME_OS_VERSION: ${{ matrix.data.os.version }}
strategy:
fail-fast: false
matrix:
compiler: [ldc-latest]
arch: [x86_64]
data:
- os:
target: macos
host: macOS-13
- os:
target: linux
host: ubuntu-latest
# Temporarily disabled
# - os:
# target: windows
# host: windows-latest
- os:
target: freebsd
host: ubuntu-latest
version: '14.0'
cross_platform_actions: true
cross_compile: true
- os:
target: openbsd
host: ubuntu-latest
version: '7.4'
cross_platform_actions: true
cross_compile: true
- os:
target: netbsd
host: ubuntu-latest
version: '10.0'
cross_platform_actions: true
cross_compile: true
include:
- data:
os:
target: macos
host: macOS-latest
compiler: ldc-latest
arch: arm64
- data:
os:
target: linux
host: ubuntu-latest
cross_compile: true
docker: true
compiler: ldc-latest
arch: arm64
- data:
os:
target: linux
host: ubuntu-latest
cross_compile: true
docker: true
compiler: ldc-latest
arch: ppc64le
- data:
os:
target: linux
host: ubuntu-latest
cross_compile: true
docker: true
compiler: ldc-latest
arch: riscv64
- data:
os:
target: linux
host: ubuntu-latest
cross_compile: true
docker: true
compiler: ldc-latest
arch: s390x
- data:
os:
target: linux
host: ubuntu-latest
cross_compile: true
docker: true
compiler: ldc-latest
arch: mips64el
docker_arch: mips64le
- data:
os:
target: linux
host: ubuntu-latest
cross_compile: true
docker: true
compiler: ldc-latest
arch: i386
docker_arch: 386
# Temporarily disabled
# - data:
# os:
# target: windows
# host: windows-latest
# compiler: ldc-latest
# arch: i386
- data:
os:
target: openbsd
host: ubuntu-latest
version: '7.4'
cross_platform_actions: true
cross_compile: true
compiler: ldc-latest
arch: arm64
- data:
os:
target: freebsd
host: ubuntu-latest
version: '14.0'
cross_platform_actions: true
cross_compile: true
compiler: ldc-latest
arch: arm64
- data:
os:
target: netbsd
host: ubuntu-latest
version: '10.0'
cross_platform_actions: true
cross_compile: true
compiler: ldc-latest
arch: arm64
- data:
os:
target: linux
host: ubuntu-latest
compiler: ldc-beta
arch: x86_64
- data:
os:
target: linux
host: ubuntu-latest
compiler: ldc-master
arch: x86_64
nightly: nightly
steps:
- name: Clone Repository
uses: actions/checkout@v4
with:
persist-credentials: false
# - name: Setup tmate session
# uses: mxschmitt/action-tmate@v3
- name: Test
if: ${{ !matrix.data.cross_platform_actions && !matrix.data.docker }}
run: ./.github/workflows/ci.sh
- name: Build Tests
if: ${{ matrix.data.cross_compile }}
run: ./.github/workflows/build_tests.sh
- name: Run Tests in VM
if: ${{ matrix.data.cross_platform_actions }}
uses: cross-platform-actions/action@v0.24.0
with:
shell: bash
operating_system: ${{ matrix.data.os.target }}
architecture: ${{ matrix.arch }}
version: ${{ matrix.data.os.version }}
environment_variables: LIME_CROSS_COMPILE
run: ./.github/workflows/ci.sh
- name: Set up QEMU
if: ${{ matrix.data.docker }}
uses: docker/setup-qemu-action@v3
with:
platforms: ${{ matrix.docker_arch }}
- name: Run Tests in Docker
if: ${{ matrix.data.docker }}
run: |
docker run \
--rm \
-v $(pwd):/${{ github.workspace }} \
-w ${{ github.workspace }} \
-e LIME_CROSS_COMPILE=${{ env.LIME_CROSS_COMPILE }} \
--platform linux/${{ matrix.docker_arch || matrix.arch }} \
debian:unstable-slim \
./.github/workflows/ci.sh
# - name: Debug
# if: ${{ failure() }}
# run: cat config/temp/mixin.d