From 7ca3405acc52c8ad99d482e69a04c3f82379ca64 Mon Sep 17 00:00:00 2001 From: weisj <31143295+weisJ@users.noreply.github.com> Date: Fri, 16 Jul 2021 21:36:50 +0200 Subject: [PATCH] Actions: Adjust java versions With the compilation of the module-info a java toolchain with version at least 11 is required. --- .github/workflows/branch-snapshot.yml | 2 +- .github/workflows/codeql-analysis.yml | 2 +- .github/workflows/gradle.yml | 24 ++++++++++++++++++++++-- .github/workflows/snapshot.yml | 4 ++-- 4 files changed, 26 insertions(+), 6 deletions(-) diff --git a/.github/workflows/branch-snapshot.yml b/.github/workflows/branch-snapshot.yml index d2c7c464..264d01f0 100644 --- a/.github/workflows/branch-snapshot.yml +++ b/.github/workflows/branch-snapshot.yml @@ -20,7 +20,7 @@ jobs: if: contains(github.event.pull_request.labels.*.name, 'published to test') uses: actions/setup-java@v1 with: - java-version: 8 + java-version: 11 - name: Extract branch name if: contains(github.event.pull_request.labels.*.name, 'published to test') shell: bash diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index a8a7940c..e18def38 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -37,7 +37,7 @@ jobs: - name: Set up JDK uses: actions/setup-java@v1 with: - java-version: 8 + java-version: 11 # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index 6263b966..224449f3 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -39,7 +39,7 @@ jobs: name: windows-test-results path: build/test_results - linux: + linux8: name: Linux (Java 8) runs-on: ubuntu-latest permissions: @@ -53,11 +53,31 @@ jobs: uses: actions/setup-java@v1 with: java-version: 8 + - name: Build + env: + PROPS_GITHUB: "-PgithubAccessToken=${{ secrets.GITHUB_TOKEN }}" + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: ./gradlew build -x test -PskipAutostyle -PskipModuleInfo -PfailIfLibraryMissing=true $(echo $PROPS_GITHUB) --no-daemon + + linux: + name: Linux (Java 11) + runs-on: ubuntu-latest + permissions: + contents: read + packages: read + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 2 + - name: Set up JDK 11 + uses: actions/setup-java@v1 + with: + java-version: 11 - name: Build & Test env: PROPS_GITHUB: "-PgithubAccessToken=${{ secrets.GITHUB_TOKEN }}" GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: xvfb-run -a -server-num=1 --server-args="-screen 0 2000x3000x16" ./gradlew build test -PskipAutostyle -PfailIfLibraryMissing=true $(echo $PROPS_GITHUB) --no-daemon + run: xvfb-run -a -server-num=1 --server-args="-screen 0 2000x3000x16" ./gradlew build test -PskipAutostyle -PfailIfLibraryMissing=true $(echo $PROPS_GITHUB) --no-daemon - name: Upload Test Results if: ${{ always() }} uses: actions/upload-artifact@v1 diff --git a/.github/workflows/snapshot.yml b/.github/workflows/snapshot.yml index 0ca8ff1b..833110a5 100644 --- a/.github/workflows/snapshot.yml +++ b/.github/workflows/snapshot.yml @@ -22,10 +22,10 @@ jobs: - uses: actions/checkout@v2 with: fetch-depth: 10 - - name: Set up JDK 8 + - name: Set up JDK 11 uses: actions/setup-java@v1 with: - java-version: 8 + java-version: 11 - name: Publish env: PROPS_RELEASE: "-Prc=1 -Pgh -Prelease=false -PskipJavadoc -PskipAutostyle -PfailIfLibraryMissing"