-
Notifications
You must be signed in to change notification settings - Fork 43
92 lines (80 loc) · 2.52 KB
/
build.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
name: build
on:
push:
branches:
- main
- master
tags:
- '**'
pull_request:
schedule:
# build it monthly: At 05:00 on day-of-month 1.
- cron: '0 5 1 * *'
workflow_dispatch:
jobs:
# verify build on one node before multiple builds on different os are started
fail-fast-build:
name: verify (ubuntu-latest, 2024-06)
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Environment
uses: ./.github/actions/setup
- name: Build
uses: ./.github/actions/build
with:
targetPlatform: 2024-06
deploy: true
pmdCiSecretPassphrase: ${{ secrets.PMD_CI_SECRET_PASSPHRASE }}
githubToken: ${{ secrets.GITHUB_TOKEN }}
- name: Upload screenshots of failed unit tests
uses: actions/upload-artifact@v4
if: ${{ failure() }}
with:
name: screenshots-ubuntu-latest-2024-06
path: net.sourceforge.pmd.eclipse.plugin.test/screenshots
if-no-files-found: ignore
build:
needs: fail-fast-build
name: verify (${{ matrix.os }}, ${{ matrix.targetPlatform }})
timeout-minutes: 60
continue-on-error: false
strategy:
matrix:
os: [ ubuntu-latest, windows-latest, macos-latest ]
targetPlatform: [ 2024-06 ]
exclude:
# exclude the fail-fast-build, which already ran
- os: ubuntu-latest
targetPlatform: 2024-06
# run other target platforms only on linux
include:
- os: ubuntu-latest
targetPlatform: 2024-03
- os: ubuntu-latest
targetPlatform: 2023-12
- os: ubuntu-latest
targetPlatform: 2023-09
fail-fast: true
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Environment
uses: ./.github/actions/setup
- name: Build
uses: ./.github/actions/build
with:
targetPlatform: ${{ matrix.targetPlatform }}
deploy: false
pmdCiSecretPassphrase: ${{ secrets.PMD_CI_SECRET_PASSPHRASE }}
githubToken: ${{ secrets.GITHUB_TOKEN }}
- name: Upload screenshots of failed unit tests
uses: actions/upload-artifact@v4
if: ${{ failure() }}
with:
name: screenshots-${{ matrix.os }}-${{ matrix.targetPlatform }}
path: net.sourceforge.pmd.eclipse.plugin.test/screenshots
if-no-files-found: ignore