Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using SonarQube with TeamCity and C# / .NET

We use TeamCity as our build server - how does one setup TeamCity to run SonarQube analysis for C# / .NET solutions?

I'm thinking we'll need to execute the MSBuild runner as a command line task since the TeamCity SonarQube runner doesn't call the MSBuild SonarQube runner.

(It would be great if http://docs.sonarqube.org/display/PLUG/C%23+Plugin described this scenario.)

EDIT

The URL in the original post has changed. Correct link is here.

like image 795
John Avatar asked Mar 15 '23 10:03

John


1 Answers

You're right: There are build step/tasks for the MSBuild SonarQube Runner available out-of-the-box for Team Foundation Server 2015 (and soon Jenkins) - but not for TeamCity. You indeed need to use the command line step/task to manually invoke the MSBuild SonarQube Runner begin and end phase, and MSBuild in between.

From there, the actual configuration and usage is identical to the command line scenario, which is why the TeamCity doesn't have its own documentation.

like image 128
Dinesh Bolkensteyn Avatar answered Mar 16 '23 22:03

Dinesh Bolkensteyn