Bump StackExchange.Redis from 2.6.122 to 2.7.10 #128
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: back - sonar cloud | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
workflow_dispatch: | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: 17 | |
distribution: 'zulu' | |
- name: Install dotnet 3.1 (sonar dependency) | |
uses: actions/setup-dotnet@v3 | |
with: | |
dotnet-version: '3.1.x' | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis | |
- name: Cache SonarCloud packages | |
uses: actions/cache@v3 | |
with: | |
path: ~\sonar\cache | |
key: ${{ runner.os }}-sonar | |
restore-keys: ${{ runner.os }}-sonar | |
- name: Setup Dotnet coverage | |
run: | | |
dotnet tool update --global dotnet-coverage | |
- name: Install SonarCloud scanners | |
run: | | |
dotnet tool update --global dotnet-sonarscanner | |
- name: Build and analyze | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN_BACK }} | |
run: | | |
dotnet-sonarscanner begin /k:"site-watcher-back-end" /o:"xilapa" /d:sonar.token="${{ secrets.SONAR_TOKEN_BACK }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.cs.vscoveragexml.reportsPaths=coverage | |
dotnet build --no-incremental | |
dotnet-coverage collect dotnet test -f xml -o coverage | |
dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN_BACK }}" |