-2

We are facing problem while analyzing c# project that how to set environmental variable and how to execute sonar runner command?

Yogesh Khurpe
  • 27
  • 3
  • 10
  • please let me know if anyone having idea about same?? – Yogesh Khurpe Dec 15 '17 at 06:47
  • 1
    Please, give more details about your problem. Did you read the documentation of Sonar Scanner for MSBuild? https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Scanner+for+MSBuild – Val Dec 15 '17 at 08:08
  • From the root folder of the project how we can analyze, execute the following commands: SonarQube.Scanner.MSBuild.exe begin /k:"org.sonarqube:sonarqube-scanner-msbuild" /n:"Project Name" /v:"1.0" MSBuild.exe /t:Rebuild SonarQube.Scanner.MSBuild.exe end – Yogesh Khurpe Dec 15 '17 at 10:30
  • Now C# Project is anlayzed successfully but even if threre is issue then on sonar dashboard it shows zero issues? why? – Yogesh Khurpe Dec 16 '17 at 06:10

1 Answers1

0

In order to run the Scanner for MSBuild from the root dir of your project you need to do one of the following:

c:\tools\sonar-scanner-msbuild.4.0\sonarqube.scanner.msbuild.exe ... msbuild ... c:\tools\sonar-scanner-msbuild.4.0\sonarqube.scanner.msbuild.exe ...

Val
  • 1,920
  • 1
  • 11
  • 14