File tree Expand file tree Collapse file tree 2 files changed +21
-25
lines changed Expand file tree Collapse file tree 2 files changed +21
-25
lines changed Original file line number Diff line number Diff line change 1
1
name : SonarCloud
2
2
on :
3
- workflow_call :
4
- inputs : {}
3
+ push :
4
+ branches : [main]
5
5
pull_request :
6
6
types : [opened, synchronize, reopened]
7
+
7
8
jobs :
8
9
analyze :
9
10
name : Analyze
@@ -29,11 +30,27 @@ jobs:
29
30
path : ~/.m2
30
31
key : ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
31
32
restore-keys : ${{ runner.os }}-m2
32
- - name : Download code coverage results
33
- uses : actions/download-artifact@v4
33
+
34
+ - name : " [Maven] Verify & generate JaCoCo XML"
35
+ env :
36
+ MAVEN_OPTS : ' -Dstyle.color=always'
37
+ MAVEN_SWITCHES : >-
38
+ --show-version
39
+ --no-transfer-progress
40
+ --update-snapshots
41
+ --fail-at-end
42
+ --batch-mode
43
+ run : mvn ${{ env.MAVEN_SWITCHES }} -P coverage verify
44
+
45
+ - name : Upload maven build result
46
+ uses : actions/upload-artifact@v4
34
47
with :
35
48
name : maven-build-target-folder
36
49
path : target
50
+
51
+ - name : List current location
52
+ run : find .
53
+
37
54
- name : Analyze project
38
55
env :
39
56
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
Original file line number Diff line number Diff line change 36
36
uses : gradle/actions/setup-gradle@v3
37
37
with :
38
38
arguments : ${{ env.GRADLE_SWITCHES }} build test
39
- - name : " [Maven] Verify & generate JaCoCo XML"
40
- env :
41
- MAVEN_OPTS : ' -Dstyle.color=always'
42
- MAVEN_SWITCHES : >-
43
- --show-version
44
- --no-transfer-progress
45
- --update-snapshots
46
- --fail-at-end
47
- --batch-mode
48
- run : mvn ${{ env.MAVEN_SWITCHES }} -P coverage verify
49
-
50
- - name : Upload maven build result
51
- uses : actions/upload-artifact@v4
52
- with :
53
- name : maven-build-target-folder
54
- path : target
55
-
56
- call :
57
- needs : [build]
58
- uses : ' ./.github/workflows/analyse.yml'
59
- secrets : inherit
60
39
61
40
publish-snapshots :
62
41
needs : [build]
You can’t perform that action at this time.
0 commit comments