mirror of
https://github.com/oliverbooth/X10D
synced 2024-11-09 23:15:40 +00:00
ci: update sonarcloud to Java 17
Also changes sonar.login option to sonar.token
This commit is contained in:
parent
1c58acd0a5
commit
74f957f0c2
16
.github/workflows/sonarcloud.yml
vendored
16
.github/workflows/sonarcloud.yml
vendored
@ -12,17 +12,18 @@ jobs:
|
|||||||
name: SonarCloud Analysis
|
name: SonarCloud Analysis
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Set up JDK 11
|
- name: Set up JDK 17
|
||||||
uses: actions/setup-java@v1
|
uses: actions/setup-java@v3
|
||||||
with:
|
with:
|
||||||
java-version: 1.11
|
java-version: 17
|
||||||
|
distribution: 'zulu'
|
||||||
|
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
||||||
|
|
||||||
- name: Cache SonarCloud packages
|
- name: Cache SonarCloud packages
|
||||||
uses: actions/cache@v1
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: ~\sonar\cache
|
path: ~\sonar\cache
|
||||||
key: ${{ runner.os }}-sonar
|
key: ${{ runner.os }}-sonar
|
||||||
@ -30,7 +31,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Cache SonarCloud scanner
|
- name: Cache SonarCloud scanner
|
||||||
id: cache-sonar-scanner
|
id: cache-sonar-scanner
|
||||||
uses: actions/cache@v1
|
uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: .\.sonar\scanner
|
path: .\.sonar\scanner
|
||||||
key: ${{ runner.os }}-sonar-scanner
|
key: ${{ runner.os }}-sonar-scanner
|
||||||
@ -49,8 +50,7 @@ jobs:
|
|||||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||||
shell: powershell
|
shell: powershell
|
||||||
run: |
|
run: |
|
||||||
dotnet tool install JetBrains.dotCover.GlobalTool -g
|
.\.sonar\scanner\dotnet-sonarscanner begin /k:"oliverbooth_X10D" /o:"oliverbooth" /d:sonar.token="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io"
|
||||||
.\.sonar\scanner\dotnet-sonarscanner begin /k:"oliverbooth_X10D" /o:"oliverbooth" /d:sonar.login="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.cs.dotcover.reportsPaths=dotCover.Output.html
|
|
||||||
dotnet build --no-incremental
|
dotnet build --no-incremental
|
||||||
dotnet dotcover test --dcReportType=HTML
|
dotnet dotcover test --dcReportType=HTML
|
||||||
.\.sonar\scanner\dotnet-sonarscanner end /d:sonar.login="${{ secrets.SONAR_TOKEN }}"
|
.\.sonar\scanner\dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}"
|
||||||
|
Loading…
Reference in New Issue
Block a user