Skip to content

Pin third-party actions to commit SHAs #34

Pin third-party actions to commit SHAs

Pin third-party actions to commit SHAs #34

Workflow file for this run

name: CI
on:
push:
branches:
- master
pull_request:
jobs:
build:
name: Build and Test
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
jdk: [8, 9, 11, 15]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@ee0669bd1cc54295c223e0bb666b733df41de1c5 # v2.7.0
- name: Set up JDK
uses: actions/setup-java@91d3aa4956ec4a53e477c4907347b5e3481be8c9 # v2.5.1
with:
java-version: ${{ matrix.jdk }}
distribution: zulu
- name: Cache Maven packages
uses: actions/cache@8492260343ad570701412c2f464a5877dc76bace # v2
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Maven Build
run: mvn -V -B -DskipTests=true install
- name: Maven Test
run: mvn -B verify
# - name: Maven Code Coverage
# if: ${{ github.ref == 'refs/heads/main' && matrix.jdk == '8' && matrix.os == 'ubuntu-latest' }}
# run: mvn -B jacoco:report coveralls:report -DrepoToken=${{ secrets.COVERALLS_TOKEN }}