-
Notifications
You must be signed in to change notification settings - Fork 73
54 lines (49 loc) · 1.43 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
name: Java CI with Maven
on:
schedule:
# run weekly to ensure to catch build being broken against upstream
- cron: "0 7 * * 1"
push:
# dependabot will create both branches and pull request
# only run on pull requests to avoid running twice and creating a release draft
branches-ignore:
- 'dependabot/**'
paths-ignore:
- 'provision/**'
- 'antora/**'
- 'doc/**'
- '.github/workflows/*.yml'
- '!.github/workflows/build.yml'
pull_request:
paths-ignore:
- 'provision/**'
- 'antora/**'
- 'doc/**'
- '.github/workflows/*.yml'
- '!.github/workflows/build.yml'
concurrency:
# Only run once for the latest commit per ref and cancel other (previous) runs.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
cache: 'maven'
- name: Cache Maven Wrapper
uses: actions/cache@v4
with:
path: |
.mvn/wrapper/maven-wrapper.jar
key: ${{ runner.os }}-maven-wrapper-${{ hashFiles('**/maven-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-maven-wrapper-
- name: Build with Maven
run: |
./mvnw -B clean verify