[Feature Request]: Expand BuildCheck editorconfig allowable syntax
Summary
EditorConfig settings for BuildChecks have rigid rules:
- casing matters for properties
- not all Roslyn severities are available, but the docs declare it to be so
Background and Motivation
Ease of use/things I banged my head against today
Proposed Feature
I'd like to see:
- the
IsEnabledproperty should supportenabledas well - casing should be case-insensitive
- a severity of
None(also,none) should be allowed to disable a rule (this is in line with the desire for case-insensitivity)
Alternative Designs
No response
Thank you! I'm going to update the usage, however would like clarify: which values were case sensitive? Trying to reproduce:
[*.csproj]
build_check.BC0101.IsEnabled=TRUE
build_check.BC0101.SEVERITY=ERROR
And the configuration applied correctly, am I missing something?
For case sensitivity I agree that the values are fine, it was the case sensitivity of the property keys that was frustrating - convention elsewhere seems to be lowercase property keys (meaning don't let .NET's Pascal case obsession leak to the editor config file).
Possibly related: https://github.com/dotnet/msbuild/issues/10315
Btw. - the:
- the IsEnabled property should support enabled as well
- a severity of None (also, none) should be allowed to disable a rule (this is in line with the desire for case-insensitivity)
Are tracked as https://github.com/dotnet/msbuild/issues/10097
Let's handle in either of those tickets, let's just prevent any possible duplication of efforts
Comment from @baronfel
Do we need IsEnabled overall in editorconfig if we are going to have support of
severity=nonewhich is equal to theIsEnabled=false
With this I do agree, and since we are in development mode I would remove the key from the infrastructure recognized keys :)
- the IsEnabled property should support enabled as well
- a severity of None (also, none) should be allowed to disable a rule (this is in line with the desire for case-insensitivity)
This goal was done as part of the ticket: https://github.com/dotnet/msbuild/issues/10097
casing should be case-insensitive
Goal here is to remove the supportability of CamelCase in configuration module for infrastructure related keys and this is tracked here: https://github.com/dotnet/msbuild/issues/10315
Conclusion
This issue is closed since all related work to the reported feature request is completed: 1 - https://github.com/dotnet/msbuild/issues/10315 solving the CamelCase configurations 2 - Severity model improved: https://github.com/dotnet/msbuild/issues/10097