Switch to SonarCloud (#17)
This commit is contained in:
parent
25c421c923
commit
dd5a440641
@ -1,6 +1,9 @@
|
|||||||
name: CI
|
name: CI
|
||||||
on:
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ main ]
|
||||||
pull_request:
|
pull_request:
|
||||||
|
types: [opened, synchronize, reopened]
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- 'README.md'
|
- 'README.md'
|
||||||
- 'LICENSE.md'
|
- 'LICENSE.md'
|
||||||
@ -15,7 +18,6 @@ jobs:
|
|||||||
- name: Check out repository code
|
- name: Check out repository code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
ref: ${{ github.event.pull_request.head.sha }}
|
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- name: Setup Python
|
- name: Setup Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
@ -29,11 +31,16 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
coverage run -m py.test -v --junitxml=testresults.xml
|
coverage run -m py.test -v --junitxml=testresults.xml
|
||||||
coverage xml
|
coverage xml
|
||||||
- uses: sonarsource/sonarqube-scan-action@master
|
- name: SonarCloud Scan
|
||||||
|
uses: SonarSource/sonarcloud-github-action@master
|
||||||
env:
|
env:
|
||||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
|
||||||
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN_CLOUD }}
|
||||||
- uses: sonarsource/sonarqube-quality-gate-action@master
|
# - uses: sonarsource/sonarqube-scan-action@master
|
||||||
timeout-minutes: 5
|
# env:
|
||||||
env:
|
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
# SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
||||||
|
# - uses: sonarsource/sonarqube-quality-gate-action@master
|
||||||
|
# timeout-minutes: 5
|
||||||
|
# env:
|
||||||
|
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
@ -1,4 +1,8 @@
|
|||||||
sonar.projectKey=luketainton_pypilot_AYHo1eOKSbMjdyWLhHhP
|
sonar.organization=luketainton
|
||||||
|
sonar.projectKey=luketainton_pypilot
|
||||||
|
# sonar.projectKey=luketainton_pypilot_AYHo1eOKSbMjdyWLhHhP
|
||||||
|
sonar.projectName=pypilot
|
||||||
|
sonar.projectVersion=1.0
|
||||||
sonar.python.version=3.10
|
sonar.python.version=3.10
|
||||||
sonar.python.coverage.reportPaths=coverage.xml
|
sonar.python.coverage.reportPaths=coverage.xml
|
||||||
sonar.python.pylint.reportPaths=lintreport.txt
|
sonar.python.pylint.reportPaths=lintreport.txt
|
||||||
|
Loading…
x
Reference in New Issue
Block a user