-
Notifications
You must be signed in to change notification settings - Fork 26
131 lines (111 loc) · 3.34 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
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
name: SmallRye Build
on:
push:
branches:
- main
- jakarta
paths-ignore:
- '.gitattributes'
- '.gitignore'
- 'LICENSE'
- 'NOTICE'
- 'README*'
pull_request:
paths-ignore:
- '.gitattributes'
- '.gitignore'
- 'LICENSE'
- 'NOTICE'
- 'README*'
jobs:
build-linux:
runs-on: ubuntu-latest
strategy:
matrix:
java: [ 11, 17 ]
name: build with JDK ${{matrix.java}} (Linux)
steps:
- uses: actions/checkout@v2
name: checkout
- uses: AdoptOpenJDK/install-jdk@v1
name: set up JDK ${{matrix.java}}
with:
version: ${{matrix.java}}
- name: Cache local Maven repository
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: build with maven
run: |
mvn -q -N io.takari:maven:0.7.7:wrapper -Dmaven=3.8.3
./mvnw -B formatter:validate verify --file pom.xml
build-windows:
runs-on: windows-latest
name: build with JDK 11 (Windows)
steps:
- uses: actions/checkout@v2
name: checkout
- uses: AdoptOpenJDK/install-jdk@v1
name: set up JDK 11
with:
version: 11
- name: Cache local Maven repository
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: build with maven
shell: bash
run: |
mvn -q -N io.takari:maven:0.7.7:wrapper -Dmaven=3.8.3
./mvnw -B formatter:validate verify --file pom.xml
build-macos:
runs-on: macos-latest
name: build with JDK 11 (Mac OS)
steps:
- uses: actions/checkout@v2
name: checkout
- uses: AdoptOpenJDK/install-jdk@v1
name: set up JDK 11
with:
version: 11
- name: Cache local Maven repository
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: build with maven
run: |
mvn -q -N io.takari:maven:0.7.7:wrapper -Dmaven=3.8.3
./mvnw -B formatter:validate verify --file pom.xml
quality:
needs: [build-linux,build-macos,build-windows]
if: github.event_name == 'push' && github.repository_owner == 'smallrye'
runs-on: ubuntu-latest
name: quality
steps:
- uses: actions/checkout@v2
- uses: AdoptOpenJDK/install-jdk@v1
with:
version: 11
- name: Cache local Maven repository
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: sonar
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
SONAR_TOKEN: ${{secrets.SONAR_TOKEN}}
run: |
mvn -q -N io.takari:maven:0.7.7:wrapper -Dmaven=3.8.3
./mvnw -B javadoc:javadoc verify --file pom.xml -Pcoverage sonar:sonar -Dsonar.projectKey=smallrye_smallrye-common -Dsonar.login=$SONAR_TOKEN