Turn off rosyln analyzers during NCrunch Build
Inspired by post http://forum.ncrunch.net/yaf_postsm7582_Build-fails-with-custom-analyzers.aspx
Rosyln analyzers in Visual studio 2015 get run during NCrunch Builds. Would it speed up compilation if analyzers were turned off in NCrunch?
I cant think of a reason why it is necessary - Visual studio gives you real time feedback in the editor and on manual compiles. I wouldn't watch the NCrunch output window for build warnings
Setting the ‘Allow code analysis’ NCrunch setting to False will now disable Roslyn analyzers.
-
Ralf Koban commented
Would be really good to have that option.
From a technical point of view it would be something like ignoring all analyzers (identifyable by <Analyzer /> XML element) that are defined in a .csproj file.
Today's workaround is to add the condition on each <ItemGroup /> element (<ItemGroup Condition="'$(NCrunch)' != '1'" >).
However, especially on large solutions where multiple developers are working on this is hard to keep consistent because these conditionsa) might be forgotten to add in the first place
b) are removed as soon as the NuGet package gets updated and have to be re-added by the developer.