Version Used: MSBuild.exe v14.0 and v15.0
Steps to Reproduce:
Expected Behavior:
/p:ErrorLog will save the Roslyn analysis results for all the projects in a solution.
Actual Behavior:
/p:ErrorLog only saves the Roslyn analysis results for the last project.
Note the effective ask here is for /errorlog compiler switch to append to the given error log file as opposed to overwrite.
Workaround for the customer is to use separate error log files per-project, but they would prefer generating a single error log file for the entire solution.
Thanks, Manish.
To clarify this is more of a blocking issue for us, than a preference. We cannot easily call MSBuild once per project; we're just 'replaying' the MSBuild cmd that was done earlier in the build.
@jcouv for triaging
FYI: The following workaround resolved this issue and we don't need this feature request anymore:
Are you guys on MSBuild 15+? If so, https://docs.microsoft.com/en-us/visualstudio/msbuild/customize-your-build might be the simplest solution for your problem. Just define a props at the root directory of the solution that sets the property ErrorLog to “$(MSBuildProjectFullPath).json”
Most helpful comment
FYI: The following workaround resolved this issue and we don't need this feature request anymore: