-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.editorconfig
More file actions
61 lines (49 loc) · 2.22 KB
/
.editorconfig
File metadata and controls
61 lines (49 loc) · 2.22 KB
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
54
55
56
57
58
59
60
61
# top-level EditorConfig
root = true
[*.cs]
charset = utf-8
end_of_line = crlf
insert_final_newline = true
indent_style = space
indent_size = 4
trim_trailing_whitespace = true
# Treat all warnings as errors via build, but also escalate here
warn_as_error = true
# C# language version
dotnet_language_version = latest
# Using directives
dotnet_sort_system_directives_first = true
dotnet_separate_import_directive_groups = true
# File layout preferences
csharp_new_line_before_open_brace = all
csharp_preserve_single_line_blocks = false
csharp_preserve_single_line_statements = false
# Nullable & analysis
build_property.Nullable = enable
build_property.TreatWarningsAsErrors = true
# Naming - private fields start with _
dotnet_naming_rule.private_fields_should_have_prefix.symbols = private_fields
dotnet_naming_rule.private_fields_should_have_prefix.style = underscore_prefix
dotnet_naming_rule.private_fields_should_have_prefix.severity = warning
# Symbol group for private fields
dotnet_naming_symbols.private_fields.applicable_accessibilities = private
dotnet_naming_symbols.private_fields.applicable_kinds = field
# Underscore style
dotnet_naming_style.underscore_prefix.capitalization = camel_case
dotnet_naming_style.underscore_prefix.required_prefix = _
# Relax StyleCop rules
dotnet_diagnostic.SA1633.severity = none # File header requirement
dotnet_diagnostic.SA1636.severity = none # File header company name text
dotnet_diagnostic.SA1639.severity = none # File header must have summary tag
dotnet_diagnostic.SA1309.severity = none # Allow private fields to start with underscore
dotnet_diagnostic.SA1101.severity = none # Project uses _camelCase fields; this. prefix is redundant
dotnet_diagnostic.SA1412.severity = none # Ignore BOM requirement
dotnet_diagnostic.SA1600.severity = none # Temporarily disable element documentation requirement
dotnet_diagnostic.SA1609.severity = none # Temporarily disable <value> doc requirement for properties
# Test sources: further relax documentation
[tests/**/*.cs]
dotnet_diagnostic.SA1600.severity = none
dotnet_diagnostic.SA1609.severity = none
dotnet_diagnostic.CS1591.severity = none
[*.{csproj,props,targets}]
indent_size = 2