forked from openmrs/openmrs-module-reporting
-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (43 loc) · 1.27 KB
/
maven.yml
File metadata and controls
50 lines (43 loc) · 1.27 KB
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
# this build is designed to replicate the Travis CI workflow
name: Build with Maven
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
permissions:
contents: read
id-token: write
jobs:
build:
strategy:
matrix:
platform: [ ubuntu-latest ]
java-version: [ 8, 11, 17, 21, 24, 25]
runs-on: ${{ matrix.platform }}
env:
PLATFORM: ${{ matrix.platform }}
JAVA_VERSION: ${{ matrix.java-version }}
steps:
- uses: actions/checkout@v4
- name: Set up JDK
uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java-version }}
distribution: 'temurin'
- name: Cache local Maven repository
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Build with Maven
run: mvn clean install --batch-mode --show-version --file pom.xml
- name: Upload coverage to Codecov
if: ${{ matrix.java-version == '25' && matrix.platform == 'ubuntu-lastest' }}
uses: codecov/codecov-action@v5
continue-on-error: true
with:
use_oidc: true