This is an automated email from the ASF dual-hosted git repository.

pottlinger pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/creadur-rat.git


The following commit(s) were added to refs/heads/master by this push:
     new d9d63c87 RAT-293: Add SonarCloud integration
d9d63c87 is described below

commit d9d63c87af6bdfa5743c450f88e62e0952036b6b
Author: P. Ottlinger <[email protected]>
AuthorDate: Sun Jan 4 21:39:28 2026 +0100

    RAT-293: Add SonarCloud integration
---
 .github/workflows/sonarcloud.yml | 36 ++++++++++++++++++++++++++++++++++++
 src/changes/changes.xml          |  3 +++
 2 files changed, 39 insertions(+)

diff --git a/.github/workflows/sonarcloud.yml b/.github/workflows/sonarcloud.yml
new file mode 100644
index 00000000..fad2e8bb
--- /dev/null
+++ b/.github/workflows/sonarcloud.yml
@@ -0,0 +1,36 @@
+name: SonarQube
+on:
+  push:
+    branches:
+      - master
+  pull_request:
+    types: [opened, synchronize, reopened]
+jobs:
+  build:
+    name: Build and analyze
+    runs-on: ubuntu-latest
+    steps:
+      - uses: actions/checkout@v4
+        with:
+          fetch-depth: 0  # Shallow clones should be disabled for a better 
relevancy of analysis
+      - name: Set up JDK 17
+        uses: actions/setup-java@v4
+        with:
+          java-version: 17
+          distribution: 'zulu' # Alternative distribution options are 
available.
+      - name: Cache SonarQube packages
+        uses: actions/cache@v4
+        with:
+          path: ~/.sonar/cache
+          key: ${{ runner.os }}-sonar
+          restore-keys: ${{ runner.os }}-sonar
+      - name: Cache Maven packages
+        uses: actions/cache@v4
+        with:
+          path: ~/.m2
+          key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
+          restore-keys: ${{ runner.os }}-m2
+      - name: Build and analyze
+        env:
+          SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
+        run: mvn -B verify 
org.sonarsource.scanner.maven:sonar-maven-plugin:sonar 
-Dsonar.projectKey=apache_creadur-rat
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index e8ed0a06..350ddf29 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -68,6 +68,9 @@ in order to be properly linked in site reports.
     </release>
     -->
     <release version="1.0.0" date="xxxx-yy-zz" description="Current SNAPSHOT - 
release to be done">
+      <action issue="RAT-293" type="add" dev="pottlinger">
+        Add integration of RAT into SonarCloud analysis now that JDK8 is 
dropped.
+      </action>
       <action issue="RAT-478" type="add" dev="pottlinger">
         Due to the switch to Java17 language level we use UTF-8 as default 
charset to process configuration and exclusion configuration files within RAT.
       </action>

Reply via email to