From 7c114dcf4bb42df46bf87fb765c003b1b994b889 Mon Sep 17 00:00:00 2001 From: amvanbaren Date: Thu, 16 Nov 2023 20:21:59 +0200 Subject: [PATCH] Sonar copy server libraries --- .github/workflows/sonar.yml | 10 ++++++---- sonar-project.properties | 4 ++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/sonar.yml b/.github/workflows/sonar.yml index 321c37443..5a313be5f 100644 --- a/.github/workflows/sonar.yml +++ b/.github/workflows/sonar.yml @@ -57,16 +57,18 @@ jobs: path: ~/.gradle/caches key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }} restore-keys: ${{ runner.os }}-gradle - - name: Print current working directory #TODO remove after debugging - run: cd ~/.gradle/caches && pwd + - name: Make server libraries directory + run: mkdir server/libraries + - name: Copy server libraries #TODO remove after debugging + run: find ~/.gradle/caches -type f -name '*.jar' -exec cp {} server/libraries \; - name: List Files #TODO remove after debugging - run: cd ~ && ls -al + run: ls -al server/libraries - name: Set up JDK uses: actions/setup-java@v1 with: java-version: 17 - name: Build Server - run: server/gradlew --no-daemon -p server build + run: server/gradlew --no-daemon -p server compileJava compileScala compileTestJava compileTestScala - name: SonarCloud Scan on PR if: github.event.workflow_run.event == 'pull_request' uses: sonarsource/sonarcloud-github-action@master diff --git a/sonar-project.properties b/sonar-project.properties index 95dd8cb77..eeef30959 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,9 +3,9 @@ sonar.organization=open-vsx sonar.sources=cli,webui,server/scripts,server/Dockerfile,server/src/dev,server/src/gatling,server/src/main/java,server/src/main/resources,.gitpod.dockerfile,.gitpod.yml sonar.tests=server/src/test sonar.java.binaries=server/build/classes/java/main -sonar.java.libraries=.gradle/caches +sonar.java.libraries=server/libraries/*.jar sonar.java.test.binaries=server/build/classes/java/test -sonar.java.test.libraries=.gradle/caches +sonar.java.test.libraries=server/libraries/*.jar # This is the name and version displayed in the SonarCloud UI. #sonar.projectName=openvsx