Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 5db8037

Browse files
committed
Add SonarCloud analysis
1 parent 71affac commit 5db8037

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

.github/workflows/maven.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,8 @@ jobs:
2323
- name: Install xvfb
2424
run: sudo apt-get install xvfb
2525
- name: Build with Maven
26-
run: xvfb-run mvn clean verify
26+
with:
27+
args: xvfb-run mvn clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.REPOSITORY_ACCESS_TOKEN }}
30+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

pom.xml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,11 @@
5454
<annotation-api.version>1.3.2</annotation-api.version>
5555
<system-rules.version>1.19.0</system-rules.version>
5656
<urm.version>1.4.8</urm.version>
57+
<!-- SonarCloud -->
58+
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
59+
<sonar.organization>iluwatar</sonar.organization>
60+
<sonar.projectKey>iluwatar_java-design-patterns</sonar.projectKey>
61+
<sonar.projectName>Java Design Patterns</sonar.projectName>
5762
</properties>
5863
<modules>
5964
<module>abstract-factory</module>
@@ -400,6 +405,11 @@
400405
</execution>
401406
</executions>
402407
</plugin>
408+
<plugin>
409+
<groupId>org.sonarsource.scanner.maven</groupId>
410+
<artifactId>sonar-maven-plugin</artifactId>
411+
<version>3.7.0.1746</version>
412+
</plugin>
403413
</plugins>
404414
</pluginManagement>
405415

0 commit comments

Comments
 (0)