|
1 |
| -# top-most EditorConfig file |
2 |
| -root = true |
3 |
| - |
4 |
| -# Don't use tabs for indentation. |
5 |
| -[*] |
6 |
| -indent_style = space |
7 |
| -trim_trailing_whitespace = true |
8 |
| -insert_final_newline = true |
9 |
| - |
10 |
| -[*.md] |
11 |
| -trim_trailing_whitespace = false |
12 |
| - |
13 |
| -# Code files |
14 |
| -[*.{cs,csx,vb,vbx}] |
15 |
| -indent_size = 4 |
16 |
| -charset = utf-8 |
17 |
| - |
18 |
| -# Shell scripts |
19 |
| -[*.sh] |
20 |
| -end_of_line = lf |
21 |
| -[*.{cmd, bat, ps1}] |
22 |
| -end_of_line = crlf |
23 |
| - |
24 |
| -# Xml project files |
25 |
| -[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}] |
26 |
| -indent_size = 2 |
27 |
| - |
28 |
| -# Xml config files |
29 |
| -[*.{props,targets,Build.targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}] |
30 |
| -indent_size = 2 |
31 |
| - |
32 |
| -# JSON files |
33 |
| -[*.json] |
34 |
| -indent_size = 2 |
35 |
| - |
36 |
| -# Dotnet code style settings: |
37 |
| -[*.{cs,vb}] |
38 |
| -# Sort using and Import directives with System.* appearing first |
39 |
| -dotnet_sort_system_directives_first = true |
40 |
| - |
41 |
| -# Avoid "this." and "Me." if not necessary |
42 |
| -dotnet_style_qualification_for_field = false : warning |
43 |
| -dotnet_style_qualification_for_property = false : warning |
44 |
| -dotnet_style_qualification_for_method = false : warning |
45 |
| -dotnet_style_qualification_for_event = false : warning |
46 |
| - |
47 |
| -# Use language keywords instead of framework type names for type references |
48 |
| -dotnet_style_predefined_type_for_locals_parameters_members = true : warning |
49 |
| -dotnet_style_predefined_type_for_member_access = true : warning |
50 |
| - |
51 |
| -# Suggest more modern language features when available |
52 |
| -dotnet_style_object_initializer = true : suggestion |
53 |
| -dotnet_style_collection_initializer = true : suggestion |
54 |
| -dotnet_style_coalesce_expression = true : suggestion |
55 |
| -dotnet_style_null_propagation = true : suggestion |
56 |
| -dotnet_style_explicit_tuple_names = true : suggestion |
57 |
| - |
58 |
| -# Naming rules - async methods to be prefixed with Async |
59 |
| -dotnet_naming_rule.async_methods_must_end_with_async.severity = warning |
60 |
| -dotnet_naming_rule.async_methods_must_end_with_async.symbols = method_symbols |
61 |
| -dotnet_naming_rule.async_methods_must_end_with_async.style = end_in_async_style |
62 |
| - |
63 |
| -dotnet_naming_symbols.method_symbols.applicable_kinds = method |
64 |
| -dotnet_naming_symbols.method_symbols.required_modifiers = async |
65 |
| - |
66 |
| -dotnet_naming_style.end_in_async_style.capitalization = pascal_case |
67 |
| -dotnet_naming_style.end_in_async_style.required_suffix = Async |
68 |
| - |
69 |
| -# Naming rules - static fields should have PascalCase |
70 |
| -dotnet_naming_rule.static_fields_should_have_prefix.severity = suggestion |
71 |
| -dotnet_naming_rule.static_fields_should_have_prefix.symbols = static_fields |
72 |
| -dotnet_naming_rule.static_fields_should_have_prefix.style = static_prefix_style |
73 |
| - |
74 |
| -dotnet_naming_symbols.static_fields.applicable_kinds = field |
75 |
| -dotnet_naming_symbols.static_fields.required_modifiers = static |
76 |
| - |
77 |
| -dotnet_naming_style.static_prefix_style.capitalization = pascal_case |
78 |
| - |
79 |
| -# Naming rules - internal and private fields should be _camelCase |
80 |
| -dotnet_naming_rule.camel_case_for_private_internal_fields.severity = suggestion |
81 |
| -dotnet_naming_rule.camel_case_for_private_internal_fields.symbols = private_internal_fields |
82 |
| -dotnet_naming_rule.camel_case_for_private_internal_fields.style = camel_case_underscore_style |
83 |
| - |
84 |
| -dotnet_naming_symbols.private_internal_fields.applicable_kinds = field |
85 |
| -dotnet_naming_symbols.private_internal_fields.applicable_accessibilities = private, internal |
86 |
| - |
87 |
| -dotnet_naming_style.camel_case_underscore_style.required_prefix = _ |
88 |
| -dotnet_naming_style.camel_case_underscore_style.capitalization = camel_case |
89 |
| - |
90 |
| -# Naming rules - private fields must start with an underscore |
91 |
| -dotnet_naming_rule.field_must_start_with_underscore.severity = warning |
92 |
| -dotnet_naming_rule.field_must_start_with_underscore.symbols = private_fields |
93 |
| -dotnet_naming_rule.field_must_start_with_underscore.style = start_underscore_style |
94 |
| - |
95 |
| -dotnet_naming_symbols.private_fields.applicable_kinds = field |
96 |
| -dotnet_naming_symbols.private_fields.applicable_accessibilities = private |
97 |
| - |
98 |
| -dotnet_naming_style.start_underscore_style.capitalization = camel_case |
99 |
| -dotnet_naming_style.start_underscore_style.required_prefix = _ |
100 |
| - |
101 |
| -# Naming rules - name all constant fields using PascalCase |
102 |
| -dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion |
103 |
| -dotnet_naming_rule.constant_fields_should_be_pascal_case.symbols = constant_fields |
104 |
| -dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style |
105 |
| - |
106 |
| -dotnet_naming_symbols.constant_fields.applicable_kinds = field |
107 |
| -dotnet_naming_symbols.constant_fields.required_modifiers = const |
108 |
| - |
109 |
| -dotnet_naming_style.pascal_case_style.capitalization = pascal_case |
110 |
| - |
111 |
| -# CSharp code style settings: |
112 |
| -[*.cs] |
113 |
| -# Prefer "var" everywhere |
114 |
| -csharp_style_var_for_built_in_types = true : suggestion |
115 |
| -csharp_style_var_when_type_is_apparent = true : suggestion |
116 |
| -csharp_style_var_elsewhere = true : suggestion |
117 |
| - |
118 |
| -csharp_style_unused_value_expression_statement_preference = discard_variable : warning |
119 |
| - |
120 |
| -# No take on method-like constructs to have a block body or be expression-bodied |
121 |
| -csharp_style_expression_bodied_methods = false : none |
122 |
| -csharp_style_expression_bodied_constructors = false : none |
123 |
| -csharp_style_expression_bodied_operators = false : none |
124 |
| - |
125 |
| -# Prefer property-like constructs to have an expression-body |
126 |
| -csharp_style_expression_bodied_properties = true : suggestion |
127 |
| -csharp_style_expression_bodied_indexers = true : suggestion |
128 |
| -csharp_style_expression_bodied_accessors = true : suggestion |
129 |
| - |
130 |
| -# Suggest more modern language features when available |
131 |
| -csharp_style_pattern_matching_over_is_with_cast_check = true : suggestion |
132 |
| -csharp_style_pattern_matching_over_as_with_null_check = true : suggestion |
133 |
| -csharp_style_inlined_variable_declaration = true : suggestion |
134 |
| -csharp_style_throw_expression = true : suggestion |
135 |
| -csharp_style_conditional_delegate_call = true : suggestion |
136 |
| -csharp_style_pattern_local_over_anonymous_function = true : suggestion |
137 |
| -csharp_prefer_simple_default_expression = true : suggestion |
138 |
| -csharp_style_deconstructed_variable_declaration = true : suggestion |
139 |
| - |
140 |
| -# Code style defaults |
141 |
| -csharp_preserve_single_line_blocks = true |
142 |
| -csharp_preserve_single_line_statements = false |
143 |
| -csharp_prefer_braces = true : suggestion |
144 |
| - |
145 |
| -# Indentation |
146 |
| -csharp_indent_block_contents = true |
147 |
| -csharp_indent_braces = false |
148 |
| -csharp_indent_case_contents = true |
149 |
| -csharp_indent_switch_labels = true |
150 |
| -csharp_indent_labels = flush_left |
151 |
| - |
152 |
| -# Space preferences |
153 |
| -csharp_space_after_cast = false |
154 |
| -csharp_space_after_colon_in_inheritance_clause = true |
155 |
| -csharp_space_after_comma = true |
156 |
| -csharp_space_after_dot = false |
157 |
| -csharp_space_after_keywords_in_control_flow_statements = true |
158 |
| -csharp_space_after_semicolon_in_for_statement = true |
159 |
| -csharp_space_around_binary_operators = before_and_after |
160 |
| -csharp_space_around_declaration_statements = do_not_ignore |
161 |
| -csharp_space_before_colon_in_inheritance_clause = true |
162 |
| -csharp_space_before_comma = false |
163 |
| -csharp_space_before_dot = false |
164 |
| -csharp_space_before_open_square_brackets = false |
165 |
| -csharp_space_before_semicolon_in_for_statement = false |
166 |
| -csharp_space_between_empty_square_brackets = false |
167 |
| -csharp_space_between_method_call_empty_parameter_list_parentheses = false |
168 |
| -csharp_space_between_method_call_name_and_opening_parenthesis = false |
169 |
| -csharp_space_between_method_call_parameter_list_parentheses = false |
170 |
| -csharp_space_between_method_declaration_empty_parameter_list_parentheses = false |
171 |
| -csharp_space_between_method_declaration_name_and_open_parenthesis = false |
172 |
| -csharp_space_between_method_declaration_parameter_list_parentheses = false |
173 |
| -csharp_space_between_parentheses = false |
174 |
| -csharp_space_between_square_brackets = false |
175 |
| - |
176 |
| -# Newline settings |
177 |
| -csharp_new_line_before_open_brace = all |
178 |
| -csharp_new_line_before_else = true |
179 |
| -csharp_new_line_before_catch = true |
180 |
| -csharp_new_line_before_finally = true |
181 |
| -csharp_new_line_before_members_in_object_initializers = true |
182 |
| -csharp_new_line_before_members_in_anonymous_types = true |
183 |
| -csharp_new_line_between_query_expression_clauses = true |
| 1 | +# top-most EditorConfig file |
| 2 | +root = true |
| 3 | + |
| 4 | +# Don't use tabs for indentation. |
| 5 | +[*] |
| 6 | +indent_style = space |
| 7 | +trim_trailing_whitespace = true |
| 8 | +insert_final_newline = true |
| 9 | + |
| 10 | +[*.md] |
| 11 | +trim_trailing_whitespace = false |
| 12 | + |
| 13 | +# Code files |
| 14 | +[*.{cs,csx,vb,vbx}] |
| 15 | +indent_size = 4 |
| 16 | +charset = utf-8 |
| 17 | + |
| 18 | +# Shell scripts |
| 19 | +[*.sh] |
| 20 | +end_of_line = lf |
| 21 | +[*.{cmd, bat, ps1}] |
| 22 | +end_of_line = crlf |
| 23 | + |
| 24 | +# Xml project files |
| 25 | +[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}] |
| 26 | +indent_size = 2 |
| 27 | + |
| 28 | +# Xml config files |
| 29 | +[*.{props,targets,Build.targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}] |
| 30 | +indent_size = 2 |
| 31 | + |
| 32 | +# JSON files |
| 33 | +[*.json] |
| 34 | +indent_size = 2 |
| 35 | + |
| 36 | +# Dotnet code style settings: |
| 37 | +[*.{cs,vb}] |
| 38 | +# Sort using and Import directives with System.* appearing first |
| 39 | +dotnet_sort_system_directives_first = true |
| 40 | + |
| 41 | +# Avoid "this." and "Me." if not necessary |
| 42 | +dotnet_style_qualification_for_field = false : warning |
| 43 | +dotnet_style_qualification_for_property = false : warning |
| 44 | +dotnet_style_qualification_for_method = false : warning |
| 45 | +dotnet_style_qualification_for_event = false : warning |
| 46 | + |
| 47 | +# Use language keywords instead of framework type names for type references |
| 48 | +dotnet_style_predefined_type_for_locals_parameters_members = true : warning |
| 49 | +dotnet_style_predefined_type_for_member_access = true : warning |
| 50 | + |
| 51 | +# Suggest more modern language features when available |
| 52 | +dotnet_style_object_initializer = true : suggestion |
| 53 | +dotnet_style_collection_initializer = true : suggestion |
| 54 | +dotnet_style_coalesce_expression = true : suggestion |
| 55 | +dotnet_style_null_propagation = true : suggestion |
| 56 | +dotnet_style_explicit_tuple_names = true : suggestion |
| 57 | + |
| 58 | +# Naming rules - async methods to be prefixed with Async |
| 59 | +dotnet_naming_rule.async_methods_must_end_with_async.severity = warning |
| 60 | +dotnet_naming_rule.async_methods_must_end_with_async.symbols = method_symbols |
| 61 | +dotnet_naming_rule.async_methods_must_end_with_async.style = end_in_async_style |
| 62 | + |
| 63 | +dotnet_naming_symbols.method_symbols.applicable_kinds = method |
| 64 | +dotnet_naming_symbols.method_symbols.required_modifiers = async |
| 65 | + |
| 66 | +dotnet_naming_style.end_in_async_style.capitalization = pascal_case |
| 67 | +dotnet_naming_style.end_in_async_style.required_suffix = Async |
| 68 | + |
| 69 | +# Naming rules - static fields should have PascalCase |
| 70 | +dotnet_naming_rule.static_fields_should_have_prefix.severity = suggestion |
| 71 | +dotnet_naming_rule.static_fields_should_have_prefix.symbols = static_fields |
| 72 | +dotnet_naming_rule.static_fields_should_have_prefix.style = static_prefix_style |
| 73 | + |
| 74 | +dotnet_naming_symbols.static_fields.applicable_kinds = field |
| 75 | +dotnet_naming_symbols.static_fields.required_modifiers = static |
| 76 | + |
| 77 | +dotnet_naming_style.static_prefix_style.capitalization = pascal_case |
| 78 | + |
| 79 | +# Naming rules - internal and private fields should be _camelCase |
| 80 | +dotnet_naming_rule.camel_case_for_private_internal_fields.severity = suggestion |
| 81 | +dotnet_naming_rule.camel_case_for_private_internal_fields.symbols = private_internal_fields |
| 82 | +dotnet_naming_rule.camel_case_for_private_internal_fields.style = camel_case_underscore_style |
| 83 | + |
| 84 | +dotnet_naming_symbols.private_internal_fields.applicable_kinds = field |
| 85 | +dotnet_naming_symbols.private_internal_fields.applicable_accessibilities = private, internal |
| 86 | + |
| 87 | +dotnet_naming_style.camel_case_underscore_style.required_prefix = _ |
| 88 | +dotnet_naming_style.camel_case_underscore_style.capitalization = camel_case |
| 89 | + |
| 90 | +# Naming rules - private fields must start with an underscore |
| 91 | +dotnet_naming_rule.field_must_start_with_underscore.severity = warning |
| 92 | +dotnet_naming_rule.field_must_start_with_underscore.symbols = private_fields |
| 93 | +dotnet_naming_rule.field_must_start_with_underscore.style = start_underscore_style |
| 94 | + |
| 95 | +dotnet_naming_symbols.private_fields.applicable_kinds = field |
| 96 | +dotnet_naming_symbols.private_fields.applicable_accessibilities = private |
| 97 | + |
| 98 | +dotnet_naming_style.start_underscore_style.capitalization = camel_case |
| 99 | +dotnet_naming_style.start_underscore_style.required_prefix = _ |
| 100 | + |
| 101 | +# Naming rules - name all constant fields using PascalCase |
| 102 | +dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion |
| 103 | +dotnet_naming_rule.constant_fields_should_be_pascal_case.symbols = constant_fields |
| 104 | +dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style |
| 105 | + |
| 106 | +dotnet_naming_symbols.constant_fields.applicable_kinds = field |
| 107 | +dotnet_naming_symbols.constant_fields.required_modifiers = const |
| 108 | + |
| 109 | +dotnet_naming_style.pascal_case_style.capitalization = pascal_case |
| 110 | + |
| 111 | +# CSharp code style settings: |
| 112 | +[*.cs] |
| 113 | +# Prefer "var" everywhere |
| 114 | +csharp_style_var_for_built_in_types = true : suggestion |
| 115 | +csharp_style_var_when_type_is_apparent = true : suggestion |
| 116 | +csharp_style_var_elsewhere = true : suggestion |
| 117 | + |
| 118 | +csharp_style_unused_value_expression_statement_preference = discard_variable : warning |
| 119 | + |
| 120 | +# No take on method-like constructs to have a block body or be expression-bodied |
| 121 | +csharp_style_expression_bodied_methods = false : none |
| 122 | +csharp_style_expression_bodied_constructors = false : none |
| 123 | +csharp_style_expression_bodied_operators = false : none |
| 124 | + |
| 125 | +# Prefer property-like constructs to have an expression-body |
| 126 | +csharp_style_expression_bodied_properties = true : suggestion |
| 127 | +csharp_style_expression_bodied_indexers = true : suggestion |
| 128 | +csharp_style_expression_bodied_accessors = true : suggestion |
| 129 | + |
| 130 | +# Suggest more modern language features when available |
| 131 | +csharp_style_pattern_matching_over_is_with_cast_check = true : suggestion |
| 132 | +csharp_style_pattern_matching_over_as_with_null_check = true : suggestion |
| 133 | +csharp_style_inlined_variable_declaration = true : suggestion |
| 134 | +csharp_style_throw_expression = true : suggestion |
| 135 | +csharp_style_conditional_delegate_call = true : suggestion |
| 136 | +csharp_style_pattern_local_over_anonymous_function = true : suggestion |
| 137 | +csharp_prefer_simple_default_expression = true : suggestion |
| 138 | +csharp_style_deconstructed_variable_declaration = true : suggestion |
| 139 | + |
| 140 | +# Code style defaults |
| 141 | +csharp_preserve_single_line_blocks = true |
| 142 | +csharp_preserve_single_line_statements = false |
| 143 | +csharp_prefer_braces = true : suggestion |
| 144 | + |
| 145 | +# Indentation |
| 146 | +csharp_indent_block_contents = true |
| 147 | +csharp_indent_braces = false |
| 148 | +csharp_indent_case_contents = true |
| 149 | +csharp_indent_switch_labels = true |
| 150 | +csharp_indent_labels = flush_left |
| 151 | + |
| 152 | +# Space preferences |
| 153 | +csharp_space_after_cast = false |
| 154 | +csharp_space_after_colon_in_inheritance_clause = true |
| 155 | +csharp_space_after_comma = true |
| 156 | +csharp_space_after_dot = false |
| 157 | +csharp_space_after_keywords_in_control_flow_statements = true |
| 158 | +csharp_space_after_semicolon_in_for_statement = true |
| 159 | +csharp_space_around_binary_operators = before_and_after |
| 160 | +csharp_space_around_declaration_statements = do_not_ignore |
| 161 | +csharp_space_before_colon_in_inheritance_clause = true |
| 162 | +csharp_space_before_comma = false |
| 163 | +csharp_space_before_dot = false |
| 164 | +csharp_space_before_open_square_brackets = false |
| 165 | +csharp_space_before_semicolon_in_for_statement = false |
| 166 | +csharp_space_between_empty_square_brackets = false |
| 167 | +csharp_space_between_method_call_empty_parameter_list_parentheses = false |
| 168 | +csharp_space_between_method_call_name_and_opening_parenthesis = false |
| 169 | +csharp_space_between_method_call_parameter_list_parentheses = false |
| 170 | +csharp_space_between_method_declaration_empty_parameter_list_parentheses = false |
| 171 | +csharp_space_between_method_declaration_name_and_open_parenthesis = false |
| 172 | +csharp_space_between_method_declaration_parameter_list_parentheses = false |
| 173 | +csharp_space_between_parentheses = false |
| 174 | +csharp_space_between_square_brackets = false |
| 175 | + |
| 176 | +# Newline settings |
| 177 | +csharp_new_line_before_open_brace = all |
| 178 | +csharp_new_line_before_else = true |
| 179 | +csharp_new_line_before_catch = true |
| 180 | +csharp_new_line_before_finally = true |
| 181 | +csharp_new_line_before_members_in_object_initializers = true |
| 182 | +csharp_new_line_before_members_in_anonymous_types = true |
| 183 | +csharp_new_line_between_query_expression_clauses = true |
0 commit comments