-
Notifications
You must be signed in to change notification settings - Fork 4
36 lines (33 loc) · 1.27 KB
/
sonar.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Sonar Scan
on:
# Trigger analysis when pushing in master or pull requests, and when creating
# a pull request.
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened]
jobs:
sonarcloud:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
with:
args: >
-Dsonar.projectKey=prabhuignoto_react-visual-grid
-Dsonar.organization=prabhuignoto
-Dsonar.sources=src/components,src/common,src/effects
-Dsonar.host.url=https://sonarcloud.io
-Dsonar.exclusions=**/node_modules/**,**/dist/**,src/examples/**
-Dsonar.coverage.exclusions=**/node_modules/**,**/dist/**,src/examples/**,**/*.test.js,**/*.test.jsx,**/*.test.ts,**/*.test.tsx
-Dsonar.login=${{ secrets.SONAR_TOKEN }}
-Dsonar.tests=src/components,src/common,src/effects
-Dsonar.test.inclusions=**/*.test.js,**/*.test.jsx,**/*.test.ts,**/*.test.tsx
-Dsonar.javascript.lcov.reportPaths=coverage/lcov.info
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}