I am executing Sonar in GitHub using SonarScanner - dotnet tool install --global dotnet-sonarscanner --version 5.2.2
- and it is providing a result.
SonarQube: Community version 7.9.4
dotnet-SonarScanner: 4.10.0 / 5.2.2 (tried with both and earlier was working with 4.10.0)
The following shell script I'm using to execute the sonar as follow:
PowerShell Script
dotnet sonarscanner begin /key:$projectKey `
/d:sonar.log.level="DEBUG" `
/v:"$(gitversion /nofetch /showvariable AssemblySemVer)" `
/d:sonar.links.scm=$repository `
/d:sonar.scm.provider="git" `
/d:sonar.scm.revision="$(git rev-parse HEAD)" `
/d:sonar.buildString="$(gitversion /nofetch /showvariable NuGetVersion)" `
/d:sonar.host.url="https://ccq.svc.myorg.com" `
/d:sonar.login=$token `
/d:sonar.cs.opencover.reportsPaths="$pwd\CodeCoverageReports\CoverageReport.xml" `
/d:sonar.cs.xunittest.reportsPaths="$pwd\TestResults\TestResults.xml"
& $msbuild $solutionName /p:Configuration=Release /t:Build -maxcpucount:1 /consoleloggerparameters:NoSummary
dotnet sonarscanner end "/d:sonar.login=$token"
But when a result is updated in SonarQube it is not analyzing the C#
files and analyzing the XML
& JS
files only.
I have crossed-checked in SonarQube > Project > Aministration > General Settings and there is no files excluded.
Can you pls share what am I missing here?