This repository has been archived by the owner on Jun 1, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (55 loc) · 1.5 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
name: Build Project
on:
push:
branches: [ master, ver/* ]
pull_request:
branches: [ master, ver/* ]
workflow_dispatch:
jobs:
setup:
runs-on: ubuntu-latest
name: Maven Setup
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
cache: 'maven'
- name: Setup Project
run: mvn clean install dependency:tree -DskipTests
build:
needs: setup
strategy:
matrix:
java-version: [8, 11, 16, 17, 18, 19]
runs-on: ubuntu-latest
name: Build Java ${{ matrix.java-version }}
steps:
- uses: actions/checkout@v4
- name: Set up JDK ${{ matrix.java-version }}
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: ${{ matrix.java-version }}
cache: 'maven'
- name: Build Project
run: mvn clean package -Dmaven.javadoc.skip=true
deploy:
runs-on: ubuntu-latest
needs: build
name: Deploy JavaDocs
if: ${{ github.event_name != 'pull_request' && github.ref_name == 'master' }}
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
cache: 'maven'
- name: Build Project
run: mvn package -DskipTests
- name: Build JavaDocs
run: bash javadoc.sh ${GITHUB_SHA::7}