1

is it possible to specify the working directory for MsBuild?

Currently, we experience when we build a Solution with MsBuild the working directory is always the directory where the solution is placed, but we want to have a generic working directory specily when we build more than one solution.

We need this functionality because the SonarQube MsBuild Scanner needs to be run in the same directory where the compile and build for MsBuild is executed.

Cheers

aumanjoa
  • 905
  • 1
  • 11
  • 30
  • Can you give more details on your solution(s) layout. Or even better open a thread on SonarQube Google group with a sample project that reproduce your issue. – Julien H. - SonarSource Team Jun 22 '17 at 14:38
  • 1
    Assuming you are using vNext build, for the msbuild task in TFS, we cannot specify the working directory. But you can try to add a Command Line or Batch script task to invoke the msbuild command, then you can reference this similar thread: https://stackoverflow.com/questions/34182934/how-can-i-change-the-working-directory-of-msbuild-sonarqube-runner-exe – Andy Li-MSFT Jun 23 '17 at 10:18

1 Answers1

0

The problem was solved using the Tfs Plugin for sonarqube

aumanjoa
  • 905
  • 1
  • 11
  • 30