@@ -219,125 +219,6 @@ jobs:
219219 if-no-files-found : error
220220
221221
222- build-windows :
223- # For any event that is not a PR, the CI will always run. In PRs, the CI
224- # can be skipped if the tag [skip-ci] is written in the title.
225- if : |
226- (github.repository_owner == 'root-project' && github.event_name != 'pull_request') ||
227- (github.event_name == 'pull_request' && !contains(github.event.pull_request.title, '[skip-ci]'))
228-
229- permissions :
230- contents : read
231-
232- strategy :
233- fail-fast : false
234- matrix :
235- # We have to get a bit creative here: GitHub actions only allows to
236- # exclude partial matches, so we artificially add the event_name as
237- # a "constant variable" that we can use to remove the Debug entries
238- # for pull requests and on branch pushes. This is further complicated
239- # by the fact that event_name is a string, but we need an array. So
240- # we construct a JSON string that we can then convert into an array.
241- event_name : ${{ fromJSON(format('["{0}"]', github.event_name)) }}
242- config : ["Debug", "Release"]
243- target_arch : [x64, x86]
244- exclude :
245- - event_name : pull_request
246- config : Debug
247- - event_name : push
248- config : Debug
249- - event_name : workflow_dispatch
250- config : Debug
251-
252- name : Windows 10 ${{ matrix.target_arch }} ${{ matrix.config }}
253-
254- runs-on : # Using '[self-hosted, windows, ${{ matrix.arch }}]' does not work for some reason :)
255- - self-hosted
256- - windows
257- - x64 # machine host, not build target
258- - target${{ matrix.target_arch }}
259-
260- steps :
261- - name : Checkout
262- uses : actions/checkout@v4
263- with :
264- ref : ${{ inputs.ref_name }}
265-
266- - name : Pull Request Build
267- if : github.event_name == 'pull_request'
268- env :
269- INCREMENTAL : ${{ !contains(github.event.pull_request.labels.*.name, 'clean build') }}
270- GITHUB_PR_ORIGIN : ${{ github.event.pull_request.head.repo.clone_url }}
271- shell : cmd
272- run : " C:\\ setenv.bat ${{ matrix.target_arch }} &&
273- python .github/workflows/root-ci-config/build_root.py
274- --buildtype ${{ matrix.config }}
275- --platform windows10
276- --incremental $INCREMENTAL
277- --base_ref ${{ github.base_ref }}
278- --sha ${{ github.sha }}
279- --pull_repository ${{ github.event.pull_request.head.repo.clone_url }}
280- --head_ref refs/pull/${{ github.event.pull_request.number }}/head:${{ github.event.pull_request.head.ref }}
281- --head_sha ${{ github.event.pull_request.head.sha }}
282- --repository ${{ github.server_url }}/${{ github.repository }}
283- --architecture ${{ matrix.target_arch }}"
284-
285- - name : Workflow dispatch/call
286- if : github.event_name == 'workflow_dispatch'
287- shell : cmd
288- run : " C:\\ setenv.bat ${{ matrix.target_arch }} &&
289- python .github/workflows/root-ci-config/build_root.py
290- --buildtype ${{ matrix.config }}
291- --platform windows10
292- --incremental ${{ inputs.incremental }}
293- --base_ref ${{ inputs.base_ref }}
294- --head_ref ${{ inputs.head_ref }}
295- --binaries ${{ inputs.binaries }}
296- --repository ${{ github.server_url }}/${{ github.repository }}
297- --architecture ${{ matrix.target_arch }}"
298-
299- - name : Nightly build
300- if : github.event_name == 'schedule'
301- shell : cmd
302- run : " C:\\ setenv.bat ${{ matrix.target_arch }} &&
303- python .github/workflows/root-ci-config/build_root.py
304- --buildtype ${{ matrix.config }}
305- --platform windows10
306- --incremental false
307- --binaries true
308- --base_ref ${{ inputs.ref_name }}
309- --repository ${{ github.server_url }}/${{ github.repository }}
310- --architecture ${{ matrix.target_arch }}"
311-
312- - name : Update build cache after push to release branch
313- if : github.event_name == 'push'
314- shell : cmd
315- run : " C:\\ setenv.bat ${{ matrix.target_arch }} &&
316- python .github/workflows/root-ci-config/build_root.py
317- --buildtype ${{ matrix.config }}
318- --platform windows10
319- --incremental false
320- --base_ref ${{ github.ref_name }}
321- --binaries ${{ startsWith(github.ref, 'refs/tags/') }}
322- --repository ${{ github.server_url }}/${{ github.repository }}
323- --architecture ${{ matrix.target_arch }}"
324-
325- - name : Upload test results
326- if : ${{ !cancelled() }}
327- uses : actions/upload-artifact@v4
328- with :
329- name : Test Results Windows ${{ matrix.target_arch }} ${{ matrix.config }}
330- path : C:/ROOT-CI/build/TestResults.xml
331-
332- - name : Upload binaries
333- if : ${{ !cancelled() && (inputs.binaries || github.event_name == 'schedule' || startsWith(github.ref, 'refs/tags/')) }}
334- uses : actions/upload-artifact@v4
335- with :
336- name : Binaries ${{ matrix.target_arch }} ${{ matrix.config }}
337- path : C:/ROOT-CI/packages/root_v*
338- if-no-files-found : error
339-
340-
341222 build-linux :
342223 # For any event that is not a PR, the CI will always run. In PRs, the CI
343224 # can be skipped if the tag [skip-ci] is written in the title.
0 commit comments