fix: update editorconfig#84
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the repository’s .editorconfig to adjust C# code style, naming rules, and diagnostic severity configuration.
Changes:
- Reorganized and simplified the C# EditorConfig rules (using directives, braces, expression-bodied members, naming rules).
- Changed
varpreference to allowvarwhen the type is apparent. - Added a diagnostics section and consolidated XML-related file indentation rules.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| dotnet_diagnostic.IDE1006.severity = warning # Enforce naming rules | ||
| dotnet_diagnostic.CA2007.severity = none # ConfigureAwait not needed in ASP.NET Core | ||
| dotnet_diagnostic.CA1050.severity = none # Types in namespaces | ||
| dotnet_diagnostic.CA2254.severity = none # Logging template constants | ||
| dotnet_diagnostic.IDE0130.severity = none # File-scoped namespace style |
There was a problem hiding this comment.
The trailing inline comments after the severity values are likely to be parsed as part of the value by EditorConfig/Roslyn (EditorConfig comments are typically only supported as full-line comments). This can make the severities invalid (e.g., value becomes warning # Enforce naming rules) and cause these diagnostics settings to be ignored. Consider moving these explanations to separate comment lines above each setting.
| dotnet_diagnostic.IDE1006.severity = warning # Enforce naming rules | |
| dotnet_diagnostic.CA2007.severity = none # ConfigureAwait not needed in ASP.NET Core | |
| dotnet_diagnostic.CA1050.severity = none # Types in namespaces | |
| dotnet_diagnostic.CA2254.severity = none # Logging template constants | |
| dotnet_diagnostic.IDE0130.severity = none # File-scoped namespace style | |
| # Enforce naming rules | |
| dotnet_diagnostic.IDE1006.severity = warning | |
| # ConfigureAwait not needed in ASP.NET Core | |
| dotnet_diagnostic.CA2007.severity = none | |
| # Types in namespaces | |
| dotnet_diagnostic.CA1050.severity = none | |
| # Logging template constants | |
| dotnet_diagnostic.CA2254.severity = none | |
| # File-scoped namespace style | |
| dotnet_diagnostic.IDE0130.severity = none |
| csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async:suggestion | ||
|
|
||
| # avoid this. unless absolutely necessary | ||
| # Avoid this. unless absolutely necessary |
There was a problem hiding this comment.
Comment capitalization/grammar: "Avoid this. unless absolutely necessary" should be a single sentence (e.g., capitalize after the period or avoid the period). This reads like a typo in a style guide comment.
| # Avoid this. unless absolutely necessary | |
| # Avoid this unless absolutely necessary. |
| dotnet_style_qualification_for_event = false:suggestion | ||
|
|
||
| # Types: use keywords instead of BCL types, and permit var only when the type is clear | ||
| # Use keywords instead of BCL types, allow var when type is apparent |
There was a problem hiding this comment.
The comment says "allow var when type is apparent", but csharp_style_var_for_built_in_types = false still prefers explicit types for built-in types even when the type is apparent. Either adjust the comment to match the rules being enforced, or change the built-in-types preference if the intent is truly to allow var whenever the type is apparent.
| # Use keywords instead of BCL types, allow var when type is apparent | |
| # Use keywords instead of BCL types; prefer explicit types for built-in types |
🤖 I have created a release *beep* *boop* --- ## [1.7.0](v1.6.0...v1.7.0) (2026-02-10) ### Features * implement sparse fieldsets (`fields[type]`) per JSON:API spec ([#82](#82)) ([d03136b](d03136b)) ### Bug Fixes * update editorconfig ([#84](#84)) ([1931137](1931137)) ### Dependencies * **nuget:** Bump csharpier from 1.2.5 to 1.2.6 ([#81](#81)) ([5f63735](5f63735)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: intility-release-bot[bot] <175299729+intility-release-bot[bot]@users.noreply.github.com>
No description provided.