|
| 1 | +# EditorConfig for ef-migration-diff |
| 2 | +# https://editorconfig.org |
| 3 | + |
| 4 | +# Top-most EditorConfig file |
| 5 | +root = true |
| 6 | + |
| 7 | +# All files |
| 8 | +[*] |
| 9 | +charset = utf-8 |
| 10 | +insert_final_newline = true |
| 11 | +trim_trailing_whitespace = true |
| 12 | +indent_style = space |
| 13 | + |
| 14 | +# C# files |
| 15 | +[*.cs] |
| 16 | +indent_size = 4 |
| 17 | +max_line_length = 120 |
| 18 | + |
| 19 | +# Code style rules |
| 20 | +dotnet_sort_system_directives_first = true |
| 21 | +dotnet_separate_import_directive_groups = false |
| 22 | + |
| 23 | +# Indentation preferences |
| 24 | +csharp_indent_case_contents = true |
| 25 | +csharp_indent_switch_labels = true |
| 26 | +csharp_indent_labels = one_less_than_current |
| 27 | +csharp_indent_block_contents = true |
| 28 | +csharp_indent_braces = false |
| 29 | +csharp_indent_case_contents_when_block = false |
| 30 | + |
| 31 | +# Wrapping preferences |
| 32 | +csharp_preserve_single_line_statements = false |
| 33 | +csharp_preserve_single_line_blocks = true |
| 34 | + |
| 35 | +# Spacing preferences |
| 36 | +csharp_space_after_cast = false |
| 37 | +csharp_space_after_keywords_in_control_flow_statements = true |
| 38 | +csharp_space_between_method_call_parameter_list_parentheses = false |
| 39 | +csharp_space_between_method_declaration_empty_parameter_list_parentheses = false |
| 40 | +csharp_space_between_method_declaration_name_and_open_parenthesis = false |
| 41 | +csharp_space_after_comma = true |
| 42 | +csharp_space_after_dot = false |
| 43 | +csharp_space_after_semicolon_in_for_statement = true |
| 44 | +csharp_space_around_binary_operators = before_and_after |
| 45 | +csharp_space_around_declaration_statements = false |
| 46 | +csharp_space_before_colon_in_inheritance_clause = true |
| 47 | +csharp_space_before_comma = false |
| 48 | +csharp_space_before_dot = false |
| 49 | +csharp_space_before_open_square_brackets = false |
| 50 | +csharp_space_between_empty_square_brackets = false |
| 51 | +csharp_space_between_square_brackets = false |
| 52 | + |
| 53 | +# New line preferences |
| 54 | +csharp_new_line_before_catch_finally_statement = true |
| 55 | +csharp_new_line_before_else = true |
| 56 | +csharp_new_line_before_members_in_anonymous_types = true |
| 57 | +csharp_new_line_before_members_in_object_initializers = true |
| 58 | +csharp_new_line_before_open_brace = all |
| 59 | +csharp_new_line_between_query_expression_clauses = true |
| 60 | + |
| 61 | +# Naming conventions |
| 62 | +# Async methods should end with Async |
| 63 | +dotnet_naming_rule.async_methods_end_in_async.severity = suggestion |
| 64 | +dotnet_naming_rule.async_methods_end_in_async.symbols = method_symbols |
| 65 | +dotnet_naming_rule.async_methods_end_in_async.style = end_in_async_style |
| 66 | + |
| 67 | +dotnet_naming_symbols.method_symbols.applicable_kinds = method |
| 68 | +dotnet_naming_symbols.method_symbols.applicable_accessibilities = * |
| 69 | +dotnet_naming_symbols.method_symbols.required_modifiers = async |
| 70 | + |
| 71 | +dotnet_naming_style.end_in_async_style.required_suffix = Async |
| 72 | +dotnet_naming_style.end_in_async_style.capitalization = pascal_case |
| 73 | + |
| 74 | +# Constants should be PascalCase |
| 75 | +dotnet_naming_rule.constants_rule.severity = suggestion |
| 76 | +dotnet_naming_rule.constants_rule.symbols = constant_symbols |
| 77 | +dotnet_naming_rule.constants_rule.style = pascal_case_style |
| 78 | + |
| 79 | +dotnet_naming_symbols.constant_symbols.applicable_kinds = field |
| 80 | +dotnet_naming_symbols.constant_symbols.required_modifiers = const |
| 81 | +dotnet_naming_symbols.constant_symbols.applicable_accessibilities = * |
| 82 | + |
| 83 | +# Private fields should be _camelCase |
| 84 | +dotnet_naming_rule.private_field_rule.severity = suggestion |
| 85 | +dotnet_naming_rule.private_field_rule.symbols = private_fields |
| 86 | +dotnet_naming_rule.private_field_rule.style = private_field_style |
| 87 | + |
| 88 | +dotnet_naming_symbols.private_fields.applicable_kinds = field |
| 89 | +dotnet_naming_symbols.private_fields.applicable_accessibilities = private |
| 90 | +dotnet_naming_symbols.private_fields.required_modifiers = |
| 91 | + |
| 92 | +dotnet_naming_style.private_field_style.required_prefix = _ |
| 93 | +dotnet_naming_style.private_field_style.capitalization = camel_case |
| 94 | + |
| 95 | +# Properties and public fields should be PascalCase |
| 96 | +dotnet_naming_rule.public_members_rule.severity = suggestion |
| 97 | +dotnet_naming_rule.public_members_rule.symbols = public_symbols |
| 98 | +dotnet_naming_rule.public_members_rule.style = pascal_case_style |
| 99 | + |
| 100 | +dotnet_naming_symbols.public_symbols.applicable_kinds = property,field,event,method |
| 101 | +dotnet_naming_symbols.public_symbols.applicable_accessibilities = public,internal,protected,protected_internal |
| 102 | +dotnet_naming_symbols.public_symbols.required_modifiers = |
| 103 | + |
| 104 | +dotnet_naming_style.pascal_case_style.capitalization = pascal_case |
| 105 | + |
| 106 | +# XML project files |
| 107 | +[*.{csproj,vbproj,proj,projitems,shproj}] |
| 108 | +indent_size = 2 |
| 109 | + |
| 110 | +# JSON files |
| 111 | +[*.json] |
| 112 | +indent_size = 2 |
| 113 | + |
| 114 | +# YAML files |
| 115 | +[*.{yml,yaml}] |
| 116 | +indent_size = 2 |
| 117 | + |
| 118 | +# Markdown files |
| 119 | +[*.md] |
| 120 | +trim_trailing_whitespace = false |
| 121 | +max_line_length = off |
| 122 | + |
| 123 | +# Batch files |
| 124 | +[*.bat] |
| 125 | +end_of_line = crlf |
| 126 | + |
| 127 | +# Shell scripts |
| 128 | +[*.sh] |
| 129 | +end_of_line = lf |
| 130 | + |
| 131 | +# Makefile |
| 132 | +[Makefile] |
| 133 | +indent_style = tab |
0 commit comments