From 97ff20ff62b3ce49fda876fab1497f6e32545534 Mon Sep 17 00:00:00 2001 From: lyozi <124312789+lyozi@users.noreply.github.com> Date: Fri, 17 May 2024 15:11:13 +0200 Subject: [PATCH] Update maven.yml --- .github/workflows/maven.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index ac9db51..52b9712 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -20,13 +20,15 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 - - name: Set up JDK 17 - uses: actions/setup-java@v4 + - uses: actions/checkout@v3 with: - java-version: '17' - distribution: 'temurin' - cache: maven + fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis + + - name: Set up JDK 21 + uses: actions/setup-java@v3 + with: + java-version: 21 + distribution: 'adopt' # Alternative distribution options are available. - name: Cache SonarCloud packages uses: actions/cache@v4 @@ -43,7 +45,7 @@ jobs: restore-keys: ${{ runner.os }}-m2 - name: Build and analyze - uses: coactions/setup-xvfb@v1.0.1 + uses: coactions/setup-xvfb@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}