File tree 2 files changed +8
-11
lines changed
2 files changed +8
-11
lines changed Original file line number Diff line number Diff line change 33
33
jobs :
34
34
build :
35
35
36
- runs-on : ubuntu-18 .04
36
+ runs-on : ubuntu-20 .04
37
37
38
38
steps :
39
39
- uses : actions/checkout@v2
@@ -49,14 +49,11 @@ jobs:
49
49
${{ runner.os }}-maven-
50
50
# Some tests need screen access
51
51
- name : Install xvfb
52
- run : sudo apt-get install xvfb
53
- # SonarQube scan does not work for forked repositories
52
+ run : sudo apt-get install -y xvfb
53
+ # The SonarQube analysis is only for the master branch of the main repository.
54
+ # SonarQube scan does not work for forked repositories try changing it to xvfb-run mvn clean verify
54
55
# See https://jira.sonarsource.com/browse/MMF-1371
55
- - name : Build with Maven
56
- if : github.ref != 'refs/heads/master'
57
- run : xvfb-run mvn clean verify
58
56
- name : Build with Maven and run SonarQube analysis
59
- if : github.ref == 'refs/heads/master'
60
57
run : xvfb-run mvn clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
61
58
env :
62
59
# These two env variables are needed for sonar analysis
Original file line number Diff line number Diff line change 33
33
jobs :
34
34
build :
35
35
36
- runs-on : ubuntu-18 .04
36
+ runs-on : ubuntu-20 .04
37
37
38
38
steps :
39
39
- uses : actions/checkout@v2
49
49
${{ runner.os }}-maven-
50
50
# Some tests need screen access
51
51
- name : Install xvfb
52
- run : sudo apt-get install xvfb
53
- # SonarQube scan does not work for forked repositories
52
+ run : sudo apt-get install -y xvfb
53
+ # This worflow is only for building Pull Requests, the master branch runs Sonar analysis on the main repository.
54
+ # SonarQube scan does not work for forked repositories.
54
55
# See https://jira.sonarsource.com/browse/MMF-1371
55
56
- name : Build with Maven
56
- if : github.ref != 'refs/heads/master'
57
57
run : xvfb-run mvn clean verify
You can’t perform that action at this time.
0 commit comments