Skip to content

Commit a1f07c1

Browse files
committed
Configuring sonar
1 parent 97f5584 commit a1f07c1

File tree

2 files changed

+18
-9
lines changed

2 files changed

+18
-9
lines changed

.github/workflows/scan.yml

+5-9
Original file line numberDiff line numberDiff line change
@@ -104,12 +104,8 @@ jobs:
104104
- name: Generate code coverage
105105
run: cargo llvm-cov --all-features --workspace --lcov --output-path lcov.info
106106

107-
# - name: SonarCloud Scan
108-
# uses: SonarSource/sonarcloud-github-action@master
109-
# env:
110-
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
111-
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
112-
# with:
113-
# args: >
114-
# -Dsonar.externalIssuesReportPaths=sonar-issues.json
115-
# -Dcommunity.rust.lcov.reportPaths=lcov.info
107+
- name: SonarQube Scan
108+
uses: SonarSource/sonarqube-scan-action@v4
109+
env:
110+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
111+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

sonar-project.properties

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
sonar.projectKey=weaveworks_sops-gitops-github-action
2+
sonar.organization=weaveworks
3+
4+
# This is the name and version displayed in the SonarCloud UI.
5+
sonar.projectName=sops-gitops-github-action
6+
#sonar.projectVersion=1.0
7+
8+
9+
# Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
10+
sonar.sources=.
11+
12+
# Encoding of the source code. Default is default system encoding
13+
sonar.sourceEncoding=UTF-8

0 commit comments

Comments
 (0)