File tree 3 files changed +56
-23
lines changed
3 files changed +56
-23
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ name : Sonarcloud CI
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ pull_request :
8
+ types : [opened, synchronize, reopened]
9
+
10
+ jobs :
11
+ SonarCloud-Build :
12
+ name : SonarCloud Build
13
+ runs-on : ubuntu-latest
14
+ steps :
15
+ - uses : actions/checkout@v4
16
+ with :
17
+ fetch-depth : 0
18
+ - name : Set up JDK 17
19
+ uses : actions/setup-java@v4
20
+ with :
21
+ java-version : 17
22
+ distribution : ' zulu'
23
+ - name : Cache SonarQube Cloud packages
24
+ uses : actions/cache@v4
25
+ with :
26
+ path : ~/.sonar/cache
27
+ key : ${{ runner.os }}-sonar
28
+ restore-keys : ${{ runner.os }}-sonar
29
+ - name : Cache Maven packages
30
+ uses : actions/cache@v4
31
+ with :
32
+ path : ~/.m2
33
+ key : ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
34
+ restore-keys : ${{ runner.os }}-m2
35
+ - name : Generate coverage report
36
+ run : mvn test jacoco:report
37
+
38
+ - name : Run SonarCloud Analysis
39
+ env :
40
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
41
+ SONAR_TOKEN : ${{ secrets.SONAR_TOKEN }}
42
+ run : mvn sonar:sonar -Dsonar.projectKey=Adyen_adyen-java-api-library
Original file line number Diff line number Diff line change 26
26
<project .build.sourceEncoding>UTF-8</project .build.sourceEncoding>
27
27
<project .reporting.outputEncoding>UTF-8</project .reporting.outputEncoding>
28
28
<swagger-core-version >1.6.14</swagger-core-version >
29
+ <sonar .organization>adyen</sonar .organization>
30
+ <sonar .host.url>https://sonarcloud.io</sonar .host.url>
29
31
</properties >
30
32
<scm >
31
33
<
connection >scm:git:
[email protected] :Adyen/adyen-java-api-library.git</
connection >
78
80
<version >0.8.12</version >
79
81
<executions >
80
82
<execution >
81
- <id >default- prepare-agent</id >
83
+ <id >prepare-agent</id >
82
84
<goals >
83
85
<goal >prepare-agent</goal >
84
86
</goals >
85
87
</execution >
88
+ <execution >
89
+ <id >report</id >
90
+ <goals >
91
+ <goal >report</goal >
92
+ </goals >
93
+ <configuration >
94
+ <formats >
95
+ <format >XML</format >
96
+ </formats >
97
+ </configuration >
98
+ </execution >
86
99
</executions >
87
100
</plugin >
88
101
<plugin >
You can’t perform that action at this time.
0 commit comments