forked from IronLanguages/ironpython3
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.editorconfig
105 lines (93 loc) · 7.26 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
; Top-most EditorConfig file
root = true
[*]
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 4
# Xml files
[*.{csproj,proj,props,targets,ruleset,config,nuspec}]
indent_size = 2
[*.cs]
csharp_new_line_before_open_brace = none
csharp_new_line_before_else = false
csharp_new_line_before_catch = false
csharp_new_line_before_finally = false
csharp_space_after_keywords_in_control_flow_statements = true
csharp_style_prefer_index_operator = false
csharp_style_prefer_range_operator = false
dotnet_sort_system_directives_first = true
dotnet_separate_import_directive_groups = true
# use language keywords instead of BCL types
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
dotnet_style_predefined_type_for_member_access = true:suggestion
# disable default VS2017 naming rule
dotnet_naming_rule.methods_and_properties_must_be_pascal_case.severity = none
dotnet_naming_rule.methods_and_properties_must_be_pascal_case.symbols = method_and_property_symbols
dotnet_naming_rule.methods_and_properties_must_be_pascal_case.style = pascal_case_style
dotnet_naming_symbols.method_and_property_symbols.applicable_kinds = method, property
dotnet_naming_symbols.method_and_property_symbols.applicable_accessibilities = *
dotnet_naming_style.pascal_case_style.capitalization = pascal_case
# enforce some code styles
dotnet_style_require_accessibility_modifiers = for_non_interface_members:error
csharp_preferred_modifier_order = public, private, protected, internal, static, extern, new, virtual, abstract, sealed, override, readonly, unsafe, volatile, async:error
# IPY01: Parameter which is marked not nullable does not have the NotNullAttribute
dotnet_diagnostic.IPY01.severity = warning
# Analyzers
dotnet_analyzer_diagnostic.severity = warning
dotnet_analyzer_diagnostic.category-style.severity = default
dotnet_diagnostic.CA1000.severity = none # CA1000: Do not declare static members on generic types
dotnet_diagnostic.CA1001.severity = suggestion # CA1001: Types that own disposable fields should be disposable
dotnet_diagnostic.CA1010.severity = suggestion # CA1010: Generic interface should also be implemented
dotnet_diagnostic.CA1018.severity = suggestion # CA1018: Mark attributes with AttributeUsageAttribute
dotnet_diagnostic.CA1036.severity = suggestion # CA1036: Override methods on comparable types
dotnet_diagnostic.CA1051.severity = none # CA1051: Do not declare visible instance fields
dotnet_diagnostic.CA1069.severity = suggestion # CA1069: Enums values should not be duplicated
dotnet_diagnostic.CA1200.severity = suggestion # CA1200: Avoid using cref tags with a prefix
dotnet_diagnostic.CA1304.severity = none # CA1304: Specify CultureInfo
dotnet_diagnostic.CA1305.severity = none # CA1305: Specify IFormatProvider
dotnet_diagnostic.CA1307.severity = suggestion # CA1307: Specify StringComparison for clarity
dotnet_diagnostic.CA1309.severity = suggestion # CA1309: Use ordinal string comparison
dotnet_diagnostic.CA1310.severity = warning # CA1310: Specify StringComparison for correctness
dotnet_diagnostic.CA1510.severity = none # CA1510: Use ArgumentNullException throw helper
dotnet_diagnostic.CA1512.severity = none # CA1512: Use ArgumentOutOfRangeException throw helper
dotnet_diagnostic.CA1513.severity = none # CA1513: Use ObjectDisposedException throw helper
dotnet_diagnostic.CA1707.severity = none # CA1707: Identifiers should not contain underscores
dotnet_diagnostic.CA1708.severity = none # CA1708: Identifiers should differ by more than case
dotnet_diagnostic.CA1710.severity = none # CA1710: Identifiers should have correct suffix
dotnet_diagnostic.CA1711.severity = none # CA1711: Identifiers should not have incorrect suffix
dotnet_diagnostic.CA1712.severity = none # CA1712: Do not prefix enum values with type name
dotnet_diagnostic.CA1715.severity = none # CA1715: Identifiers should have correct prefix
dotnet_diagnostic.CA1716.severity = none # CA1716: Identifiers should not match keywords
dotnet_diagnostic.CA1720.severity = none # CA1720: Identifier contains type name
dotnet_diagnostic.CA1725.severity = suggestion # CA1725: Parameter names should match base declaration
dotnet_diagnostic.CA1805.severity = suggestion # CA1805: Do not initialize unnecessarily
dotnet_diagnostic.CA1806.severity = none # CA1806: Do not ignore method results
dotnet_diagnostic.CA1816.severity = suggestion # CA1816: Dispose methods should call SuppressFinalize
dotnet_diagnostic.CA1822.severity = none # CA1822: Mark members as static
dotnet_diagnostic.CA1830.severity = suggestion # CA1830: Prefer strongly-typed Append and Insert method overloads on StringBuilder
dotnet_diagnostic.CA1834.severity = suggestion # CA1834: Consider using 'StringBuilder.Append(char)' when applicable
dotnet_diagnostic.CA1837.severity = suggestion # CA1837: Use 'Environment.ProcessId'
dotnet_diagnostic.CA1838.severity = suggestion # CA1838: Avoid 'StringBuilder' parameters for P/Invokes
dotnet_diagnostic.CA1845.severity = none # CA1845: Use span-based 'string.Concat'
dotnet_diagnostic.CA1846.severity = none # CA1846: Prefer 'AsSpan' over 'Substring'
dotnet_diagnostic.CA1847.severity = none # CA1847: Use char literal for a single character lookup
dotnet_diagnostic.CA1852.severity = suggestion # CA1852: Seal internal types
dotnet_diagnostic.CA1854.severity = suggestion # CA1854: Prefer the 'IDictionary.TryGetValue(TKey, out TValue)' method
dotnet_diagnostic.CA1859.severity = suggestion # CA1859: Use concrete types when possible for improved performance
dotnet_diagnostic.CA1861.severity = suggestion # CA1861: Avoid constant arrays as arguments
dotnet_diagnostic.CA1863.severity = none # CA1863: Use 'CompositeFormat'
dotnet_diagnostic.CA2101.severity = suggestion # CA2101: Specify marshaling for P/Invoke string arguments
dotnet_diagnostic.CA2201.severity = none # CA2201: Do not raise reserved exception types
dotnet_diagnostic.CA2208.severity = suggestion # CA2208: Instantiate argument exceptions correctly
dotnet_diagnostic.CA2211.severity = none # CA2211: Non-constant fields should not be visible
dotnet_diagnostic.CA2219.severity = suggestion # CA2219: Do not raise exceptions in finally clauses
dotnet_diagnostic.CA2229.severity = suggestion # CA2229: Implement serialization constructors
dotnet_diagnostic.CA2249.severity = suggestion # CA2249: Consider using 'string.Contains' instead of 'string.IndexOf'
dotnet_diagnostic.CA3075.severity = suggestion # CA3075: Insecure DTD processing in XML
dotnet_diagnostic.CA5350.severity = suggestion # CA5350: Do Not Use Weak Cryptographic Algorithms
dotnet_diagnostic.CA5351.severity = suggestion # CA5351: Do Not Use Broken Cryptographic Algorithms
dotnet_diagnostic.CA5359.severity = suggestion # CA5359: Do Not Disable Certificate Validation
dotnet_diagnostic.CA5372.severity = suggestion # CA5372: Use XmlReader For XPathDocument
dotnet_diagnostic.SYSLIB1045.severity = suggestion # SYSLIB1045: Use 'RegexGeneratorAttribute' to generate the regular expression implementation at compile-time
dotnet_diagnostic.SYSLIB1054.severity = suggestion # SYSLIB1054: Use 'LibraryImportAttribute' instead of 'DllImportAttribute' to generate P/Invoke marshalling code at compile time