Skip to content
This repository was archived by the owner on Jun 5, 2025. It is now read-only.

Commit f732791

Browse files
committed
sonar fix
1 parent 67198ff commit f732791

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

.github/workflows/main.yml

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
name: Build
21

2+
name: SonarCloud
33
on:
44
push:
55
branches:
@@ -18,25 +18,23 @@ jobs:
1818
with:
1919
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
2020
- name: Set up JDK 22
21-
uses: actions/setup-java@v2
21+
uses: actions/setup-java@v3
2222
with:
2323
distribution: 'temurin' # or 'adopt', depending on your preference
2424
java-version: '22'
25-
- name: Cache SonarQube packages
26-
uses: actions/cache@v1
25+
- name: Cache SonarCloud packages
26+
uses: actions/cache@v3
2727
with:
2828
path: ~/.sonar/cache
2929
key: ${{ runner.os }}-sonar
3030
restore-keys: ${{ runner.os }}-sonar
3131
- name: Cache Maven packages
32-
uses: actions/cache@v1
32+
uses: actions/cache@v3
3333
with:
3434
path: ~/.m2
3535
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
3636
restore-keys: ${{ runner.os }}-m2
3737
- name: Build and analyze
3838
env:
3939
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
40-
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
41-
run: mvn clean verify sonar:sonar -Dsonar.projectKey=${{ secrets.SONAR_PROJECT_KEY }} -Dsonar.host.url=${{ secrets.SONAR_HOST_URL }} -Dsonar.login=${{ secrets.SONAR_TOKEN }} -Dsonar.organization={{ secrets.SONAR_PROJECT_ORG }}
42-
40+
run: mvn clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.projectKey=SVAdithya_KafkaStudy

0 commit comments

Comments
 (0)