diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9c5e159..ab65db6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,14 +2,28 @@ name: Build and Test on: [push, pull_request, workflow_dispatch] jobs: build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: Set up JDK 21 - uses: actions/setup-java@v4 - with: - java-version: '21' - distribution: 'temurin' - cache: maven - - name: Build with Maven - run: mvn --batch-mode --update-snapshots verify + runs-on: ${{ matrix.os }} + continue-on-error: ${{ matrix.experimental }} + strategy: + matrix: + os: [ubuntu-latest, macOS-latest, windows-latest] + jdk: [ 21 ] + experimental: [false] + steps: + - uses: actions/checkout@v4 + with: + lfs: true + - name: Cache Maven packages + uses: actions/cache@v1 + with: + path: ~/.m2 + key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} + restore-keys: ${{ runner.os }}-m2 + - name: Set up JDK ${{ matrix.jdk }} + uses: actions/setup-java@v4 + with: + distribution: adopt + java-version: ${{ matrix.jdk }} + cache: maven + - name: Build + run: mvn --batch-mode test \ No newline at end of file