-
Notifications
You must be signed in to change notification settings - Fork 1
/
.editorconfig
53 lines (43 loc) · 1.73 KB
/
.editorconfig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# EditorConfig is awesome: https://EditorConfig.org
# top-most EditorConfig file
root = true
[*]
# Unit-style newlines with a newline ending every file
indent_style = space
charset = utf-8
end_of_line = lf
trim_trailing_whitespace = true
[*.cs]
indent_size = 4
dotnet_sort_system_directives_first = true
# Import namespaces per file
csharp_using_directive_placement = outside_namespace:error
# Use namespace per file
csharp_style_namespace_declarations = file_scoped:warning
# No need to match folder structure. Use 'Sync Namespaces' if you must.
dotnet_style_namespace_match_folder = false
# Use int x = .. over Int32
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
# Use int.MaxValue over Int32.MaxValue
dotnet_style_predefined_type_for_member_access = true:suggestion
csharp_prefer_simple_default_expression = true:warning
# Never use var
csharp_style_var_for_built_in_types = false:warning
# Use x is null .. over x = null
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:warning
# Always use accessibility, except for interface member
dotnet_style_require_accessibility_modifiers = for_non_interace_members:error
# Braces settings
csharp_prefer_braces = true
# Newline preference
insert_final_newline = true
csharp_new_line_before_open_brace = all
csharp_new_line_before_else = true
csharp_new_line_before_catch = true
csharp_new_line_before_finally = true
csharp_new_line_before_members_in_object_initializers = true
csharp_new_line_before_members_in_anonymous_types = true
# Never pad unnecessary blank lines
dotnet_style_allow_multiple_blank_lines_experimental = false:warning
# CA2016: Forward the 'CancellationToken' parameter to methods that take one
dotnet_diagnostic.CA2016.severity = suggestion