1- # Remove the line below if you want to inherit .editorconfig settings from higher directories
2- root = true
3-
41# C# files
52[* .cs ]
63
@@ -23,40 +20,40 @@ dotnet_sort_system_directives_first = false
2320file_header_template = unset
2421
2522# this. and Me. preferences
26- dotnet_style_qualification_for_event = false
23+ dotnet_style_qualification_for_event = false : suggestion
2724dotnet_style_qualification_for_field = false
28- dotnet_style_qualification_for_method = false
29- dotnet_style_qualification_for_property = false
25+ dotnet_style_qualification_for_method = false : suggestion
26+ dotnet_style_qualification_for_property = false : suggestion
3027
3128# Language keywords vs BCL types preferences
32- dotnet_style_predefined_type_for_locals_parameters_members = true
33- dotnet_style_predefined_type_for_member_access = true
29+ dotnet_style_predefined_type_for_locals_parameters_members = true : warning
30+ dotnet_style_predefined_type_for_member_access = true : warning
3431
3532# Parentheses preferences
36- dotnet_style_parentheses_in_arithmetic_binary_operators = never_if_unnecessary
37- dotnet_style_parentheses_in_other_binary_operators = never_if_unnecessary
38- dotnet_style_parentheses_in_other_operators = never_if_unnecessary
39- dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity
33+ dotnet_style_parentheses_in_arithmetic_binary_operators = never_if_unnecessary:suggestion
34+ dotnet_style_parentheses_in_other_binary_operators = never_if_unnecessary:suggestion
35+ dotnet_style_parentheses_in_other_operators = never_if_unnecessary:suggestion
36+ dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity:suggestion
4037
4138# Modifier preferences
4239dotnet_style_require_accessibility_modifiers = for_non_interface_members
4340
4441# Expression-level preferences
45- dotnet_style_coalesce_expression = true
42+ dotnet_style_coalesce_expression = true : warning
4643dotnet_style_collection_initializer = true
4744dotnet_style_explicit_tuple_names = true
4845dotnet_style_namespace_match_folder = true
49- dotnet_style_null_propagation = true
46+ dotnet_style_null_propagation = true : warning
5047dotnet_style_object_initializer = true
5148dotnet_style_operator_placement_when_wrapping = beginning_of_line
52- dotnet_style_prefer_auto_properties = true
49+ dotnet_style_prefer_auto_properties = true : suggestion
5350dotnet_style_prefer_compound_assignment = true
54- dotnet_style_prefer_conditional_expression_over_assignment = true
55- dotnet_style_prefer_conditional_expression_over_return = true
51+ dotnet_style_prefer_conditional_expression_over_assignment = true : warning
52+ dotnet_style_prefer_conditional_expression_over_return = true : warning
5653dotnet_style_prefer_inferred_anonymous_type_member_names = true
5754dotnet_style_prefer_inferred_tuple_names = true
58- dotnet_style_prefer_is_null_check_over_reference_equality_method = true
59- dotnet_style_prefer_simplified_boolean_expressions = true
55+ dotnet_style_prefer_is_null_check_over_reference_equality_method = true : warning
56+ dotnet_style_prefer_simplified_boolean_expressions = true : warning
6057dotnet_style_prefer_simplified_interpolation = true
6158
6259# Field preferences
@@ -70,62 +67,62 @@ dotnet_remove_unnecessary_suppression_exclusions = none
7067
7168# New line preferences
7269dotnet_style_allow_multiple_blank_lines_experimental = true
73- dotnet_style_allow_statement_immediately_after_block_experimental = true
70+ dotnet_style_allow_statement_immediately_after_block_experimental = false
7471
7572# ### C# Coding Conventions ####
7673
7774# var preferences
78- csharp_style_var_elsewhere = true
79- csharp_style_var_for_built_in_types = true
80- csharp_style_var_when_type_is_apparent = true
75+ csharp_style_var_elsewhere = false
76+ csharp_style_var_for_built_in_types = false
77+ csharp_style_var_when_type_is_apparent = true : suggestion
8178
8279# Expression-bodied members
83- csharp_style_expression_bodied_accessors = true
84- csharp_style_expression_bodied_constructors = when_on_single_line
85- csharp_style_expression_bodied_indexers = true
86- csharp_style_expression_bodied_lambdas = true
87- csharp_style_expression_bodied_local_functions = true
88- csharp_style_expression_bodied_methods = true
89- csharp_style_expression_bodied_operators = when_on_single_line
90- csharp_style_expression_bodied_properties = true
80+ csharp_style_expression_bodied_accessors = true : suggestion
81+ csharp_style_expression_bodied_constructors = when_on_single_line:silent
82+ csharp_style_expression_bodied_indexers = true : suggestion
83+ csharp_style_expression_bodied_lambdas = true : suggestion
84+ csharp_style_expression_bodied_local_functions = true : suggestion
85+ csharp_style_expression_bodied_methods = true : suggestion
86+ csharp_style_expression_bodied_operators = true : suggestion
87+ csharp_style_expression_bodied_properties = true : suggestion
9188
9289# Pattern matching preferences
93- csharp_style_pattern_matching_over_as_with_null_check = true
94- csharp_style_pattern_matching_over_is_with_cast_check = true
95- csharp_style_prefer_not_pattern = true
96- csharp_style_prefer_pattern_matching = true
90+ csharp_style_pattern_matching_over_as_with_null_check = true : warning
91+ csharp_style_pattern_matching_over_is_with_cast_check = true : warning
92+ csharp_style_prefer_not_pattern = true : warning
93+ csharp_style_prefer_pattern_matching = true : suggestion
9794csharp_style_prefer_switch_expression = true
9895
9996# Null-checking preferences
100- csharp_style_conditional_delegate_call = true
97+ csharp_style_conditional_delegate_call = true : warning
10198
10299# Modifier preferences
103100csharp_prefer_static_local_function = true
104101csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async
105102
106103# Code-block preferences
107- csharp_prefer_braces = when_multiline
108- csharp_prefer_simple_using_statement = true
109- csharp_style_namespace_declarations = file_scoped
104+ csharp_prefer_braces = when_multiline:silent
105+ csharp_prefer_simple_using_statement = true : suggestion
106+ csharp_style_namespace_declarations = file_scoped:suggestion
110107
111108# Expression-level preferences
112109csharp_prefer_simple_default_expression = true
113110csharp_style_deconstructed_variable_declaration = true
114111csharp_style_implicit_object_creation_when_type_is_apparent = true
115112csharp_style_inlined_variable_declaration = true
116113csharp_style_pattern_local_over_anonymous_function = true
117- csharp_style_prefer_index_operator = true
118- csharp_style_prefer_null_check_over_type_check = true
119- csharp_style_prefer_range_operator = true
120- csharp_style_throw_expression = true
114+ csharp_style_prefer_index_operator = true : silent
115+ csharp_style_prefer_null_check_over_type_check = true : warning
116+ csharp_style_prefer_range_operator = true : silent
117+ csharp_style_throw_expression = true : warning
121118csharp_style_unused_value_assignment_preference = discard_variable
122119csharp_style_unused_value_expression_statement_preference = discard_variable
123120
124121# 'using' directive preferences
125- csharp_using_directive_placement = outside_namespace
122+ csharp_using_directive_placement = outside_namespace:warning
126123
127124# New line preferences
128- csharp_style_allow_blank_line_after_colon_in_constructor_initializer_experimental = true
125+ csharp_style_allow_blank_line_after_colon_in_constructor_initializer_experimental = false : warning
129126csharp_style_allow_blank_lines_between_consecutive_braces_experimental = true
130127csharp_style_allow_embedded_statements_on_same_line_experimental = true
131128
@@ -217,3 +214,18 @@ dotnet_naming_style.begins_with_i.required_prefix = I
217214dotnet_naming_style.begins_with_i.required_suffix =
218215dotnet_naming_style.begins_with_i.word_separator =
219216dotnet_naming_style.begins_with_i.capitalization = pascal_case
217+ csharp_style_prefer_extended_property_pattern = true :suggestion
218+
219+ [* .{cs,vb} ]
220+ dotnet_style_operator_placement_when_wrapping = beginning_of_line
221+ tab_width = 4
222+ indent_size = 4
223+ end_of_line = crlf
224+ dotnet_style_coalesce_expression = true :warning
225+ dotnet_style_null_propagation = true :warning
226+ dotnet_style_prefer_is_null_check_over_reference_equality_method = true :warning
227+ dotnet_style_prefer_auto_properties = true :suggestion
228+ dotnet_style_qualification_for_property = false :suggestion
229+
230+ # RCS1123: Add parentheses when necessary.
231+ dotnet_diagnostic.RCS1123.severity = silent
0 commit comments