Skip to content

Commit 2756e83

Browse files
authored
chore: update SonarCloud action in CI to minvws/action-sonarqube (#25)
* chore: update SonarCloud action in CI workflow to minvws/action-sonarqube * chore: rename 'Run SonarCloud scanner' step to 'Run SonarQube scan' * chore: add SonarCloud job to CI workflow * chore: update actions/checkout to v5 and remove redundant steps from SonarQube job * chore: add checkout step to SonarCloud job in CI workflow * test: test SonarCloud job in CI workflow * chore: refactor SonarCloud job setup in CI workflow
1 parent d389773 commit 2756e83

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

.github/workflows/ci.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
runs-on: ubuntu-22.04
1717
steps:
1818
- name: Checkout
19-
uses: actions/checkout@v4
19+
uses: actions/checkout@v5
2020
with:
2121
fetch-depth: 0
2222
- name: Install PHP
@@ -32,8 +32,18 @@ jobs:
3232
run: composer phpcs
3333
- name: Execute tests (Unit and Feature)
3434
run: composer test
35-
- name: 'Run SonarCloud scanner'
36-
if: ${{contains(github.ref, '/pull/')}}
37-
uses: SonarSource/[email protected]
38-
env:
39-
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
35+
36+
sonar:
37+
name: SonarCloud
38+
runs-on: ubuntu-22.04
39+
needs: validate
40+
steps:
41+
- name: Checkout repository
42+
uses: actions/checkout@v5
43+
with:
44+
fetch-depth: 0
45+
46+
- name: Run SonarQube scan
47+
uses: minvws/action-sonarqube@v1
48+
with:
49+
sonar-token: ${{ secrets.SONAR_TOKEN }}

0 commit comments

Comments
 (0)