-
Notifications
You must be signed in to change notification settings - Fork 54
52 lines (49 loc) · 1.57 KB
/
ci.yaml
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
name: CI
on:
push:
branches:
- "main"
pull_request:
workflow_dispatch:
concurrency:
group:
${{ github.repository }}-${{ github.workflow }}-${{ github.event.number || github.head_ref || github.run_id || github.sha }}
cancel-in-progress: true
permissions:
contents: write
jobs:
build:
name: Build on ${{ matrix.os }} with Java ${{ matrix.java }}
strategy:
fail-fast: false
matrix:
java: [ 8, 11 ]
os: [ ubuntu-22.04, macos-13 ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java }}
distribution: 'temurin'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
add-job-summary-as-pr-comment: on-failure
dependency-graph: generate-and-submit
build-scan-publish: true
build-scan-terms-of-service-url: "https://gradle.com/terms-of-service"
build-scan-terms-of-service-agree: "yes"
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Run build with Gradle wrapper
run: ./gradlew build --stacktrace --warning-mode all
- name: Upload build reports
uses: actions/upload-artifact@v4
if: always()
with:
name: build-reports-${{ matrix.os }}-${{ matrix.java }}
path: build/reports/
- name: Run checks
run: ./gradlew check test integrationTest jacocoTestReport --stacktrace --warning-mode all