forked from christosservos/Alamofire
-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (35 loc) · 1.07 KB
/
sonar2.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
37
38
39
40
name: sonarcloud
on:
push:
branches:
- master
- main
- testMAIN
pull_request:
types: [opened, synchronize, reopened]
workflow_dispatch:
jobs:
sonarcloud:
name: SonarCloud
runs-on: ubuntu-latest
steps:
- name: Checkout action
uses: actions/checkout@v3
# with:
# fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: EXPORT PK
run: |
echo "PROJECTKEY=${{ github.repository_owner}}_$(echo "REPOSITORY_NAME=${github.repository#*/}"" >> $GITHUB_ENV
- name: ECHO PK -- troubleshooting step
run: |
echo $PROJECTKEY
echo $PWD
- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
with:
args: >
-Dsonar.organization=christosservos
-Dsonar.projectKey=${{ env.PROJECTKEY }}
# -Dsonar.tests=Tests/
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}