coverlet

Форк
0
/
.editorconfig 
229 строк · 10.1 Кб
1
# To learn more about .editorconfig see https://aka.ms/editorconfigdocs
2

3
# top-most EditorConfig file
4
root = true
5

6
###############################
7
# Core EditorConfig Options   #
8
###############################
9
# All files
10
[*]
11
insert_final_newline = true
12
indent_style = space
13
indent_size = 4
14
trim_trailing_whitespace = true
15

16
file_header_template = Copyright (c) Toni Solarin-Sodara\nLicensed under the MIT license. See LICENSE file in the project root for full license information.
17

18
# XML project files
19
[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}]
20
indent_size = 2
21
charset = utf-8
22

23
# XML config files
24
[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}]
25
indent_size = 2
26

27
# Xml build files
28
[*.builds]
29
indent_size = 2
30

31
# Xml files
32
[*.{xml,stylecop,resx,ruleset}]
33
indent_size = 2
34

35
# YAML config files
36
[*.{yml,yaml}]
37
indent_size = 2
38

39
# Shell scripts
40
[*.sh]
41
end_of_line = lf
42
[*.{cmd,bat}]
43
end_of_line = crlf
44

45
# Code files
46
[*.{cs,csx,vb,vbx}]
47
indent_size = 2
48
insert_final_newline = true
49
charset = utf-8-bom
50
###############################
51
# .NET Coding Conventions     #
52
###############################
53
[*.{cs,vb}]
54
# Organize usings
55
dotnet_sort_system_directives_first = true
56
## IDE0005: Using directive is unnecessary.
57
dotnet_diagnostic.IDE0005.severity = warning
58
## IDE0007 use 'var' instead of explicit type
59
dotnet_diagnostic.IDE0007.severity = none
60
# License header
61
file_header_template = Copyright (c) Toni Solarin-Sodara\nLicensed under the MIT license. See LICENSE file in the project root for full license information.
62
## IDE0073: The file header is missing or not located at the top of the file
63
dotnet_diagnostic.IDE0073.severity = warning
64
# this. preferences
65
dotnet_style_qualification_for_field = false:warning
66
dotnet_style_qualification_for_property = false:warning
67
dotnet_style_qualification_for_method = false:warning
68
dotnet_style_qualification_for_event = false:warning
69
# Language keywords vs BCL types preferences
70
dotnet_style_predefined_type_for_locals_parameters_members = true:silent
71
dotnet_style_predefined_type_for_member_access = true:silent
72
# Parentheses preferences
73
dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity:silent
74
dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity:silent
75
dotnet_style_parentheses_in_other_binary_operators = always_for_clarity:silent
76
dotnet_style_parentheses_in_other_operators = never_if_unnecessary:silent
77
# Modifier preferences
78
dotnet_style_require_accessibility_modifiers = for_non_interface_members:silent
79
dotnet_style_readonly_field = true:warning
80
## IDE0044: Add readonly modifier
81
dotnet_diagnostic.IDE0044.severity = warning
82
# Expression-level preferences
83
dotnet_style_object_initializer = true:suggestion
84
dotnet_style_collection_initializer = true:suggestion
85
dotnet_style_explicit_tuple_names = true:suggestion
86
dotnet_style_null_propagation = true:suggestion
87
dotnet_style_coalesce_expression = true:suggestion
88
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:warning
89
dotnet_style_prefer_inferred_tuple_names = true:suggestion
90
dotnet_style_prefer_inferred_anonymous_type_member_names = true:suggestion
91
dotnet_style_prefer_auto_properties = true:warning
92
dotnet_style_prefer_conditional_expression_over_assignment = true:silent
93
dotnet_style_prefer_conditional_expression_over_return = true:silent
94
# CA1805: Do not initialize unnecessarily
95
dotnet_diagnostic.CA1805.severity = warning
96
# IDE0063: Use simple 'using' statement
97
dotnet_diagnostic.IDE0063.severity = warning
98
# IDE0057: Use range operator
99
dotnet_diagnostic.IDE0057.severity = warning
100
# IDE0075: Simplify conditional expression
101
dotnet_diagnostic.IDE0075.severity = warning
102
# IDE0071: Simplify interpolation
103
dotnet_diagnostic.IDE0071.severity = warning
104
# CA1829: Use Length/Count property instead of Count() when available
105
dotnet_diagnostic.CA1829.severity = warning
106
# CA1827: Do not use Count() or LongCount() when Any() can be used
107
dotnet_diagnostic.CA1827.severity = warning
108
###############################
109
# Naming Conventions          #
110
###############################
111
# Name all constant fields using PascalCase
112
dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion
113
dotnet_naming_rule.constant_fields_should_be_pascal_case.symbols  = constant_fields
114
dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style
115
dotnet_naming_symbols.constant_fields.applicable_kinds   = field
116
dotnet_naming_symbols.constant_fields.required_modifiers = const
117
dotnet_naming_style.pascal_case_style.capitalization = pascal_case
118
# Static fields should have s_ prefix
119
dotnet_naming_rule.static_fields_should_have_prefix.severity = suggestion
120
dotnet_naming_rule.static_fields_should_have_prefix.symbols  = static_fields
121
dotnet_naming_rule.static_fields_should_have_prefix.style = static_prefix_style
122
dotnet_naming_symbols.static_fields.applicable_kinds   = field
123
dotnet_naming_symbols.static_fields.required_modifiers = static
124
dotnet_naming_symbols.static_fields.applicable_accessibilities = private, internal, private_protected
125
dotnet_naming_style.static_prefix_style.required_prefix = s_
126
dotnet_naming_style.static_prefix_style.capitalization = camel_case
127
# Internal and private fields should be _camelCase
128
dotnet_naming_rule.camel_case_for_private_internal_fields.severity = suggestion
129
dotnet_naming_rule.camel_case_for_private_internal_fields.symbols  = private_internal_fields
130
dotnet_naming_rule.camel_case_for_private_internal_fields.style = camel_case_underscore_style
131
dotnet_naming_symbols.private_internal_fields.applicable_kinds = field
132
dotnet_naming_symbols.private_internal_fields.applicable_accessibilities = private, internal
133
dotnet_naming_style.camel_case_underscore_style.required_prefix = _
134
dotnet_naming_style.camel_case_underscore_style.capitalization = camel_case
135
# IDE1006: Naming Styles
136
dotnet_diagnostic.IDE1006.severity = warning
137
# IDE0090: Use 'new(...)'
138
dotnet_diagnostic.IDE0090.severity = warning
139
dotnet_style_operator_placement_when_wrapping = beginning_of_line
140
tab_width = 2
141
end_of_line = crlf
142
###############################
143
# C# Coding Conventions       #
144
###############################
145
[*.cs]
146
# Organize usings
147
csharp_using_directive_placement = outside_namespace:silent
148
# var preferences - use keywords instead of BCL types, and permit var only when the type is clear
149
csharp_style_var_for_built_in_types = false:warning
150
csharp_style_var_when_type_is_apparent = true:warning
151
csharp_style_var_elsewhere = false:warning
152
# Expression-bodied members
153
csharp_style_expression_bodied_methods = false:silent
154
csharp_style_expression_bodied_constructors = false:silent
155
csharp_style_expression_bodied_operators = false:silent
156
csharp_style_expression_bodied_properties = true:silent
157
csharp_style_expression_bodied_indexers = true:silent
158
csharp_style_expression_bodied_accessors = true:silent
159
# Pattern matching preferences
160
csharp_style_pattern_matching_over_is_with_cast_check = true:warning
161
csharp_style_pattern_matching_over_as_with_null_check = true:warning
162
csharp_style_prefer_not_pattern = true
163
## IDE0083: Use pattern matching
164
dotnet_diagnostic.IDE0083.severity = warning
165
# Null-checking preferences
166
csharp_style_throw_expression = true:warning
167
csharp_style_conditional_delegate_call = true:warning
168
# Modifier preferences
169
csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async:warning
170
# Expression-level preferences
171
csharp_prefer_braces = true:silent
172
csharp_style_deconstructed_variable_declaration = true:suggestion
173
csharp_prefer_simple_default_expression = true:warning
174
## IDE0034: Simplify 'default' expression
175
dotnet_diagnostic.IDE0034.severity = warning
176
csharp_style_pattern_local_over_anonymous_function = true:suggestion
177
csharp_style_inlined_variable_declaration = true:warning
178
###############################
179
# C# Formatting Rules         #
180
###############################
181
# New line preferences
182
csharp_new_line_before_open_brace = all
183
csharp_new_line_before_else = true
184
csharp_new_line_before_catch = true
185
csharp_new_line_before_finally = true
186
csharp_new_line_before_members_in_object_initializers = true
187
csharp_new_line_before_members_in_anonymous_types = true
188
csharp_new_line_between_query_expression_clauses = true
189
dotnet_style_allow_multiple_blank_lines_experimental=false:warning
190
# Indentation preferences
191
csharp_indent_case_contents = true
192
csharp_indent_switch_labels = true
193
csharp_indent_block_contents = true
194
csharp_indent_braces = false
195
csharp_indent_case_contents_when_block = true
196
csharp_indent_labels = one_less_than_current
197
# Space preferences
198
csharp_space_after_cast = false
199
csharp_space_after_colon_in_inheritance_clause = true
200
csharp_space_after_comma = true
201
csharp_space_after_dot = false
202
csharp_space_after_keywords_in_control_flow_statements = true
203
csharp_space_after_semicolon_in_for_statement = true
204
csharp_space_around_binary_operators = before_and_after
205
csharp_space_around_declaration_statements = do_not_ignore
206
csharp_space_before_colon_in_inheritance_clause = true
207
csharp_space_before_comma = false
208
csharp_space_before_dot = false
209
csharp_space_before_open_square_brackets = false
210
csharp_space_before_semicolon_in_for_statement = false
211
csharp_space_between_empty_square_brackets = false
212
csharp_space_between_method_call_empty_parameter_list_parentheses = false
213
csharp_space_between_method_call_name_and_opening_parenthesis = false
214
csharp_space_between_method_call_parameter_list_parentheses = false
215
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
216
csharp_space_between_method_declaration_name_and_open_parenthesis = false
217
csharp_space_between_method_declaration_parameter_list_parentheses = false
218
csharp_space_between_parentheses = false
219
csharp_space_between_square_brackets = false
220
# Wrapping preferences
221
csharp_preserve_single_line_statements = true
222
csharp_preserve_single_line_blocks = true
223
csharp_prefer_simple_using_statement = true:suggestion
224
csharp_style_namespace_declarations = block_scoped:silent
225
csharp_style_prefer_method_group_conversion = true:silent
226
csharp_style_prefer_top_level_statements = true:silent
227
csharp_style_prefer_primary_constructors = true:suggestion
228
csharp_style_expression_bodied_lambdas = true:silent
229
csharp_style_expression_bodied_local_functions = false:silent
230

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.