I am having SonarQube version 7.9.1 and I am running sonar scan through jenkins, It scans all the file but unable to scan .cs and sql file for my MS(dotnet) project. How can I resolve this issue.
sonar-project.properties
sonar.projectKey=MSProject
sonar.projectName=MSProject
sonar.projectVersion=1.0
# Enable the Visual Studio bootstrapper
sonar.visualstudio.enable=true
# Language
sonar.language=cs
# Comma-separated paths to directories with sources (required)
sonar.sources= .
# Encoding of sources files
sonar.sourceEncoding=UTF-8
Also I can see some warnings in jenkins logs from where I am running sonarscanner.Not sure though If it is related.
WARN: Property missing: 'sonar.cs.analyzer.projectOutPaths'. No protobuf files will be loaded for this project.
WARN: No Roslyn issues report found for this project.
First, your version is past EOL. You should upgrade to either the latest version or the current LTS at your earliest convenience. Your upgrade path is:
Regarding your actual question, you appear to be trying to use the vanilla SonarScanner to analyze C# code. That won’t work; you need to use SonarScanner for .NET. The docs should get you started.
I was running sonar scanner for MSBuild through jenkins, so is there any plugin through which I can achieve this without installing dotnet-sonarscanner.
I am getting bit confuse how to run sonarscanner for MS build via jenkins. Also wanted to know do I need to install dotnet core also on my jenkins server to run sonarscanner for msbuild.