File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3131 - uses : actions/checkout@v2
3232 - name : Check
3333 run : ./gradlew test
34-
35- sonar :
36- name : Build
37- runs-on : ubuntu-latest
38- steps :
39- - uses : actions/checkout@v2
40- with :
41- # Shallow clones should be disabled for a better relevancy of analysis
42- fetch-depth : 0
43- - name : Set up JDK
44- uses : actions/setup-java@v1
45- with :
46- java-version : ${{ env.JAVA_VERSION }}
47- - name : Cache SonarCloud packages
48- uses : actions/cache@v1
49- with :
50- path : ~/.sonar/cache
51- key : ${{ runner.os }}-sonar
52- restore-keys : ${{ runner.os }}-sonar
53- - name : Cache Gradle packages
54- uses : actions/cache@v1
55- with :
56- path : ~/.gradle/caches
57- key : ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
58- restore-keys : ${{ runner.os }}-gradle
59- - name : Build and analyze
60- env :
61- # Needed to get PR information, if any
62- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
63- # Sonar login token with 'Execute Analysis' privileges
64- SONAR_TOKEN : ${{ secrets.SONAR_TOKEN }}
65- run : ./gradlew build sonarqube --info
Original file line number Diff line number Diff line change 1- name : CodeQL
1+ name : Code Analysis
22
33on :
44 push :
6464
6565 - name : Perform CodeQL Analysis
6666 uses : github/codeql-action/analyze@v1
67+
68+ sonar :
69+ name : Sonarqube
70+ runs-on : ubuntu-latest
71+ steps :
72+ - uses : actions/checkout@v2
73+ with :
74+ # Shallow clones should be disabled for a better relevancy of analysis
75+ fetch-depth : 0
76+ - name : Set up JDK
77+ uses : actions/setup-java@v1
78+ with :
79+ java-version : ${{ env.JAVA_VERSION }}
80+ - name : Cache SonarCloud packages
81+ uses : actions/cache@v1
82+ with :
83+ path : ~/.sonar/cache
84+ key : ${{ runner.os }}-sonar
85+ restore-keys : ${{ runner.os }}-sonar
86+ - name : Cache Gradle packages
87+ uses : actions/cache@v1
88+ with :
89+ path : ~/.gradle/caches
90+ key : ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
91+ restore-keys : ${{ runner.os }}-gradle
92+ - name : Build and analyze
93+ env :
94+ # Needed to get PR information, if any
95+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
96+ # Sonar login token with 'Execute Analysis' privileges
97+ SONAR_TOKEN : ${{ secrets.SONAR_TOKEN }}
98+ run : ./gradlew build sonarqube --info
You can’t perform that action at this time.
0 commit comments