11root = true
2- # EditorConfig: http://EditorConfig.org
3-
4- # top-most EditorConfig file
52
63[* ]
74indent_style = space
85
9-
106[* .cs ]
117indent_size = 4
128charset = utf-8
139
10+ # Redundant accessor body
11+ resharper_redundant_accessor_body_highlighting = error
12+
13+ # Replace with field keyword
14+ resharper_replace_with_field_keyword_highlighting = error
15+
16+ # Replace with single call to Single(..)
17+ resharper_replace_with_single_call_to_single_highlighting = error
18+
19+ # Replace with single call to SingleOrDefault(..)
20+ resharper_replace_with_single_call_to_single_or_default_highlighting = error
21+
22+ # Replace with single call to LastOrDefault(..)
23+ resharper_replace_with_single_call_to_last_or_default_highlighting = error
24+
25+ # Replace with single call to Last(..)
26+ resharper_replace_with_single_call_to_last_highlighting = error
27+
28+ # Replace with single call to First(..)
29+ resharper_replace_with_single_call_to_first_highlighting = error
30+
31+ # Replace with single call to FirstOrDefault(..)
32+ resharper_replace_with_single_call_to_first_or_default_highlighting = error
33+
34+ # Replace with single call to Any(..)
35+ resharper_replace_with_single_call_to_any_highlighting = error
36+
37+ # Replace with single call to Count(..)
38+ resharper_replace_with_single_call_to_count_highlighting = error
39+
40+ # Declare types in namespaces
41+ dotnet_diagnostic.CA1050.severity = none
42+
43+ # Use Literals Where Appropriate
44+ dotnet_diagnostic.CA1802.severity = error
45+
46+ # Potentially misleading parameter name in lambda or local function
47+ resharper_all_underscore_local_parameter_name_highlighting = none
48+
49+ # Redundant explicit collection creation in argument of 'params' parameter
50+ resharper_redundant_explicit_params_array_creation_highlighting = error
51+
52+ # Do not initialize unnecessarily
53+ dotnet_diagnostic.CA1805.severity = error
54+
55+ # Avoid unsealed attributes
56+ dotnet_diagnostic.CA1813.severity = error
57+
58+ # Test for empty strings using string length
59+ dotnet_diagnostic.CA1820.severity = none
60+
61+ # Remove empty finalizers
62+ dotnet_diagnostic.CA1821.severity = error
63+
64+ # Mark members as static
65+ dotnet_diagnostic.CA1822.severity = error
66+
67+ # Avoid unused private fields
68+ dotnet_diagnostic.CA1823.severity = error
69+
70+ # Avoid zero-length array allocations
71+ dotnet_diagnostic.CA1825.severity = error
72+
73+ # Use property instead of Linq Enumerable method
74+ dotnet_diagnostic.CA1826.severity = error
75+
76+ # Do not use Count()/LongCount() when Any() can be used
77+ dotnet_diagnostic.CA1827.severity = error
78+ dotnet_diagnostic.CA1828.severity = error
79+
80+ # Use Length/Count property instead of Enumerable.Count method
81+ dotnet_diagnostic.CA1829.severity = error
82+
83+ # Prefer strongly-typed Append and Insert method overloads on StringBuilder
84+ dotnet_diagnostic.CA1830.severity = error
85+
86+ # Use AsSpan instead of Range-based indexers for string when appropriate
87+ dotnet_diagnostic.CA1831.severity = error
88+
89+ # Use AsSpan instead of Range-based indexers for string when appropriate
90+ dotnet_diagnostic.CA1831.severity = error
91+ dotnet_diagnostic.CA1832.severity = error
92+ dotnet_diagnostic.CA1833.severity = error
93+
94+ # Use StringBuilder.Append(char) for single character strings
95+ dotnet_diagnostic.CA1834.severity = error
96+
97+ # Prefer IsEmpty over Count when available
98+ dotnet_diagnostic.CA1836.severity = error
99+
100+ # Prefer IsEmpty over Count when available
101+ dotnet_diagnostic.CA1836.severity = error
102+
103+ # Use Environment.ProcessId instead of Process.GetCurrentProcess().Id
104+ dotnet_diagnostic.CA1837.severity = error
105+
106+ # Use Environment.ProcessPath instead of Process.GetCurrentProcess().MainModule.FileName
107+ dotnet_diagnostic.CA1839.severity = error
108+
109+ # Use Environment.CurrentManagedThreadId instead of Thread.CurrentThread.ManagedThreadId
110+ dotnet_diagnostic.CA1840.severity = error
111+
112+ # Prefer Dictionary Contains methods
113+ dotnet_diagnostic.CA1841.severity = error
114+
115+ # Do not use WhenAll with a single task
116+ dotnet_diagnostic.CA1842.severity = error
117+
118+ # Do not use WhenAll/WaitAll with a single task
119+ dotnet_diagnostic.CA1842.severity = error
120+ dotnet_diagnostic.CA1843.severity = error
121+
122+ # Use span-based 'string.Concat'
123+ dotnet_diagnostic.CA1845.severity = error
124+
125+ # Prefer AsSpan over Substring
126+ dotnet_diagnostic.CA1846.severity = error
127+
128+ # Use string.Contains(char) instead of string.Contains(string) with single characters
129+ dotnet_diagnostic.CA1847.severity = error
130+
131+ # Prefer static HashData method over ComputeHash
132+ dotnet_diagnostic.CA1850.severity = error
133+
134+ # Possible multiple enumerations of IEnumerable collection
135+ dotnet_diagnostic.CA1851.severity = error
136+
137+ # Unnecessary call to Dictionary.ContainsKey(key)
138+ dotnet_diagnostic.CA1853.severity = error
139+
140+ # Prefer the IDictionary.TryGetValue(TKey, out TValue) method
141+ dotnet_diagnostic.CA1854.severity = error
142+
143+ # Use Span<T>.Clear() instead of Span<T>.Fill()
144+ dotnet_diagnostic.CA1855.severity = error
145+
146+ # Incorrect usage of ConstantExpected attribute
147+ dotnet_diagnostic.CA1856.severity = error
148+
149+ # The parameter expects a constant for optimal performance
150+ dotnet_diagnostic.CA1857.severity = error
151+
152+ # Use StartsWith instead of IndexOf
153+ dotnet_diagnostic.CA1858.severity = error
154+
155+ # Avoid using Enumerable.Any() extension method
156+ dotnet_diagnostic.CA1860.severity = error
157+
158+ # Avoid constant arrays as arguments
159+ dotnet_diagnostic.CA1861.severity = error
160+
161+ # Use the StringComparison method overloads to perform case-insensitive string comparisons
162+ dotnet_diagnostic.CA1862.severity = error
163+
164+ # Prefer the IDictionary.TryAdd(TKey, TValue) method
165+ dotnet_diagnostic.CA1864.severity = error
166+
167+ # Use string.Method(char) instead of string.Method(string) for string with single char
168+ dotnet_diagnostic.CA1865.severity = error
169+ dotnet_diagnostic.CA1866.severity = error
170+ dotnet_diagnostic.CA1867.severity = error
171+
172+ # Unnecessary call to 'Contains' for sets
173+ dotnet_diagnostic.CA1868.severity = error
174+
175+ # Cache and reuse 'JsonSerializerOptions' instances
176+ dotnet_diagnostic.CA1869.severity = error
177+
178+ # Use a cached 'SearchValues' instance
179+ dotnet_diagnostic.CA1870.severity = error
14180
15181# Microsoft .NET properties
16182trim_trailing_whitespace = true
17183csharp_preferred_modifier_order = public, private, protected, internal, new, static, abstract, virtual, sealed, readonly, override, extern, unsafe, volatile, async:suggestion
18184resharper_namespace_body = file_scoped
19185dotnet_naming_rule.private_constants_rule.severity = warning
20- dotnet_naming_rule.private_constants_rule.style = upper_camel_case_style
186+ dotnet_naming_rule.private_constants_rule.style = lower_camel_case_style
21187dotnet_naming_rule.private_constants_rule.symbols = private_constants_symbols
22188dotnet_naming_rule.private_instance_fields_rule.severity = warning
23189dotnet_naming_rule.private_instance_fields_rule.style = lower_camel_case_style
@@ -26,7 +192,7 @@ dotnet_naming_rule.private_static_fields_rule.severity = warning
26192dotnet_naming_rule.private_static_fields_rule.style = lower_camel_case_style
27193dotnet_naming_rule.private_static_fields_rule.symbols = private_static_fields_symbols
28194dotnet_naming_rule.private_static_readonly_rule.severity = warning
29- dotnet_naming_rule.private_static_readonly_rule.style = upper_camel_case_style
195+ dotnet_naming_rule.private_static_readonly_rule.style = lower_camel_case_style
30196dotnet_naming_rule.private_static_readonly_rule.symbols = private_static_readonly_symbols
31197dotnet_naming_style.lower_camel_case_style.capitalization = camel_case
32198dotnet_naming_style.upper_camel_case_style.capitalization = pascal_case
@@ -53,7 +219,7 @@ resharper_arrange_object_creation_when_type_evident_highlighting = error
53219resharper_arrange_object_creation_when_type_not_evident_highlighting = error
54220resharper_arrange_redundant_parentheses_highlighting = error
55221resharper_arrange_static_member_qualifier_highlighting = error
56- resharper_arrange_this_qualifier_highlighting = hint
222+ resharper_arrange_this_qualifier_highlighting = error
57223resharper_arrange_type_member_modifiers_highlighting = none
58224resharper_built_in_type_reference_style_for_member_access_highlighting = hint
59225resharper_built_in_type_reference_style_highlighting = hint
@@ -64,7 +230,8 @@ resharper_field_can_be_made_read_only_local_highlighting = none
64230resharper_merge_into_logical_pattern_highlighting = warning
65231resharper_merge_into_pattern_highlighting = error
66232resharper_method_has_async_overload_highlighting = warning
67- resharper_partial_type_with_single_part_highlighting = error
233+ # because stop rider giving errors before source generators have run
234+ resharper_partial_type_with_single_part_highlighting = warning
68235resharper_redundant_base_qualifier_highlighting = warning
69236resharper_redundant_cast_highlighting = error
70237resharper_redundant_empty_object_creation_argument_list_highlighting = error
@@ -73,6 +240,7 @@ resharper_redundant_name_qualifier_highlighting = error
73240resharper_redundant_suppress_nullable_warning_expression_highlighting = error
74241resharper_redundant_using_directive_highlighting = error
75242resharper_redundant_verbatim_string_prefix_highlighting = error
243+ resharper_redundant_lambda_signature_parentheses_highlighting = error
76244resharper_replace_substring_with_range_indexer_highlighting = warning
77245resharper_suggest_var_or_type_built_in_types_highlighting = error
78246resharper_suggest_var_or_type_elsewhere_highlighting = error
@@ -95,11 +263,11 @@ dotnet_style_predefined_type_for_locals_parameters_members = true:error
95263dotnet_style_predefined_type_for_member_access = true :error
96264
97265# Suggest more modern language features when available
98- dotnet_style_object_initializer = true :suggestion
99- dotnet_style_collection_initializer = true :suggestion
100- dotnet_style_coalesce_expression = false :suggestion
101- dotnet_style_null_propagation = true :suggestion
102- dotnet_style_explicit_tuple_names = true :suggestion
266+ dotnet_style_object_initializer = true :error
267+ dotnet_style_collection_initializer = true :error
268+ dotnet_style_coalesce_expression = false :error
269+ dotnet_style_null_propagation = true :error
270+ dotnet_style_explicit_tuple_names = true :error
103271
104272# Prefer "var" everywhere
105273csharp_style_var_for_built_in_types = true :error
@@ -140,6 +308,9 @@ resharper_wrap_before_binary_pattern_op = false
140308resharper_wrap_object_and_collection_initializer_style = chop_always
141309resharper_place_simple_initializer_on_single_line = false
142310
311+ # space
312+ resharper_space_around_lambda_arrow = true
313+
143314dotnet_style_require_accessibility_modifiers = never:error
144315resharper_place_type_constraints_on_same_line = false
145316resharper_blank_lines_inside_namespace = 0
@@ -160,6 +331,10 @@ resharper_braces_for_lock = required
160331resharper_braces_for_fixed = required
161332resharper_braces_for_for = required
162333
334+ resharper_return_value_of_pure_method_is_not_used_highlighting = error
335+
336+ resharper_all_underscore_local_parameter_name_highlighting = none
337+
163338# Xml files
164339[* .{xml,config,nuspec,resx,vsixmanifest,csproj,targets,props,fsproj} ]
165340indent_size = 2
@@ -169,4 +344,14 @@ resharper_space_before_self_closing = true
169344ij_xml_space_inside_empty_tag = true
170345
171346[* .json ]
172- indent_size = 2
347+ indent_size = 2
348+
349+ # Verify settings
350+ [* .{received,verified}.{txt,xml,json,md,sql,csv,html,md} ]
351+ charset = " utf-8-bom"
352+ end_of_line = lf
353+ indent_size = unset
354+ indent_style = unset
355+ insert_final_newline = false
356+ tab_width = unset
357+ trim_trailing_whitespace = false
0 commit comments