Add ECJ support #2436
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
pull_request: | |
branches: | |
- main | |
- v5 | |
push: | |
branches: | |
- main | |
- v5 | |
workflow_call: {} | |
workflow_dispatch: {} | |
jobs: | |
validate: | |
name: Validation steps | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Run ShellCheck | |
uses: ludeeus/action-shellcheck@master | |
with: | |
check_together: 'yes' | |
scandir: './scripts' | |
- name: Validate codecov.yml | |
shell: bash | |
run: curl -vvv --fail --data-binary @- https://codecov.io/validate < codecov.yml | |
build: | |
name: Build on JDK ${{ matrix.java-version }} (${{ matrix.os-name }}) | |
runs-on: ${{ matrix.os-name }} | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- java-version: 17 | |
os-name: ubuntu-latest | |
- java-version: 17 | |
os-name: windows-latest | |
- java-version: 17 | |
os-name: macos-latest | |
- java-version: 21 | |
os-name: ubuntu-latest | |
- java-version: GA | |
os-name: ubuntu-latest | |
- java-version: EA | |
os-name: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 2 | |
- name: Initialize JDK from Temurin | |
if: ${{ matrix.java-version != 'GA' && matrix.java-version != 'EA' }} | |
uses: actions/setup-java@v4 | |
with: | |
java-version: ${{ matrix.java-version }} | |
distribution: 'temurin' | |
- name: Initialize JDK from Oracle | |
if: ${{ matrix.java-version == 'GA' || matrix.java-version == 'EA' }} | |
uses: oracle-actions/setup-java@v1 | |
with: | |
website: jdk.java.net | |
release: ${{ matrix.java-version }} | |
- name: Maven cache | |
uses: actions/cache@v4 | |
env: | |
cache-name: maven-cache | |
with: | |
path: ~/.m2 | |
key: build-${{ env.cache-name }} | |
- name: Compile and run tests | |
shell: bash | |
run: ./mvnw -B -U clean verify | |
- name: Upload to codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
name: tests-java-${{ matrix.java-version }}-os-${{ matrix.os-name }} | |
token: ${{ secrets.CODECOV_TOKEN }} | |
- name: Stash reports | |
uses: actions/upload-artifact@v4 | |
if: always() | |
with: | |
name: reports-${{ matrix.java-version }}-${{ matrix.os-name }} | |
if-no-files-found: error | |
path: | | |
**/surefire-reports/** | |
**/failsafe-reports/** | |
**/build*.log | |
retention-days: 30 |