I have a new YAML pipeline in Azure DevOps with the following task:
- task: MSBuild@1
  displayName: 'Build MgzJsonService'
  inputs:
    solution: 'apps/MgzJsonService/MgzJsonService.csproj'
    platform: 'Any CPU'
    configuration: 'Release'
    msbuildArguments: '/p:OutputPath="$(build.artifactstagingdirectory)\MgzJsonService" /t:Build /m /p:RestorePackages=false /consoleloggerparameters:ErrorsOnly '
    clean: true
When the build is completed and the artifact is uploaded my Web.Config is not transformed using the Web.Release.config.
But when I add the same task twice, with Output Path another folder, the second build does transform my Web.Config using the Web.Release.config.
Why does it only work if I build the project twice?
