Is there a way to make the build fail on warning?
I can update ruleset and make all rules action="Error" but that is very tedious.
You can turn on Treat Warnings as Errors, but make sure to only do so for command line builds:
https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/2592d5b3572490da5196dd730af95882348f9565/StyleCop.Analyzers/Directory.Build.props#L25-L28
Can we do this at solution level or pass it as additional parameter ?
Most helpful comment
Can we do this at solution level or pass it as additional parameter ?