fix jdk 21 builds #510
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
# This workflow will build a Java project with Maven | ||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven | ||
name: Eclipse Collections Kata CI Build | ||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
jobs: | ||
project-build: | ||
strategy: | ||
matrix: | ||
# os: [macos-latest, ubuntu-latest, windows-latest] | ||
os: [ubuntu-latest] | ||
java-version: [11, 17, 21] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Git Checkout | ||
uses: actions/checkout@v3 | ||
- name: Set JDK ${{ matrix.java-version }} from jdk.java.net | ||
uses: oracle-actions/setup-java@v1 | ||
with: | ||
website: jdk.java.net | ||
release: ${{ matrix.java-version }} | ||
if: ${{matrix.java-version != 11 && matrix.java-version != 17 && matrix.java-version != 21}} | ||
- name: Set JDK ${{ matrix.java-version }} from Zulu | ||
uses: actions/setup-java@v3 | ||
with: | ||
distribution: 'zulu' | ||
java-version: ${{ matrix.java-version }} | ||
if: ${{matrix.java-version == 11 || matrix.java-version == 17 || matrix.java-version = 21}} | ||
Check failure on line 36 in .github/workflows/maven.yml GitHub Actions / Eclipse Collections Kata CI BuildInvalid workflow file
|
||
- name: JDK Version | ||
run: java --version | ||
- name: Enable Maven Cache | ||
uses: actions/cache@v3 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | ||
restore-keys: | | ||
${{ runner.os }}-maven- | ||
- name: Maven | ||
run: mvn install -Dmaven.javadoc.skip=true -B -V | ||
env: | ||
MAVEN_OPTS: "-Dmaven.repo.local=$HOME/.m2/repository -Xmx1g -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss:SSS" | ||
if: ${{matrix.java-version == 11}} | ||
- name: Maven | ||
run: mvn install -f pom-jdk17.xml -Dmaven.javadoc.skip=true -B -V | ||
env: | ||
MAVEN_OPTS: "-Dmaven.repo.local=$HOME/.m2/repository -Xmx1g -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss:SSS" | ||
if: ${{matrix.java-version != 11}} |