forked from EngRajabi/Enum.Source.Generator
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.editorconfig
174 lines (118 loc) · 5.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
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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
; Top-most http://editorconfig.org/ file
root = true
[*]
insert_final_newline = true
indent_style = space
indent_size = 4
[project.json]
indent_size = 2
[*.cs]
# force file scoped namespaces
csharp_style_namespace_declarations = file_scoped:warning
# CA1062: Validate arguments of public methods
dotnet_diagnostic.CA1062.severity = suggestion
# MA0026 : Complete the task
dotnet_diagnostic.MA0026.severity = suggestion
# CA1308: In method 'urlToLower', replace the call to 'ToLowerInvariant' with 'ToUpperInvariant' (CA1308)
dotnet_diagnostic.CA1308.severity = suggestion
# CA1040: Avoid empty interfaces
dotnet_diagnostic.CA1040.severity = suggestion
# CA1829 Use the "Count" property instead of Enumerable.Count()
dotnet_diagnostic.CA1829.severity = suggestion
# Use 'Count' property here instead.
dotnet_diagnostic.S2971.severity = suggestion
# S1135 : Complete the task
dotnet_diagnostic.S1135.severity = suggestion
# S2479: Replace the control character at position 7 by its escape sequence
dotnet_diagnostic.S2479.severity = suggestion
# CA2007: Consider calling ConfigureAwait on the awaited task
dotnet_diagnostic.CA2007.severity = suggestion
# MA0004: Use Task.ConfigureAwait(false) as the current SynchronizationContext is not needed
dotnet_diagnostic.MA0004.severity = suggestion
# CA1056: Change the type of property 'Url' from 'string' to 'System.Uri'
dotnet_diagnostic.CA1056.severity = suggestion
# CA1054: Change the type of parameter of the method to allow a Uri to be passed as a 'System.Uri' object
dotnet_diagnostic.CA1054.severity = suggestion
# CA1055: Change the return type of method from 'string' to 'System.Uri'
dotnet_diagnostic.CA1055.severity = suggestion
# S4457: Split this method into two, one handling parameters check and the other handling the asynchronous code.
dotnet_diagnostic.S4457.severity = suggestion
# AsyncFixer01: Unnecessary async/await usage
dotnet_diagnostic.AsyncFixer01.severity = suggestion
# AsyncFixer02: Long-running or blocking operations inside an async method
dotnet_diagnostic.AsyncFixer02.severity = error
# VSTHRD103: Call async methods when in an async method
dotnet_diagnostic.VSTHRD103.severity = error
# AsyncFixer03: Fire & forget async void methods
dotnet_diagnostic.AsyncFixer03.severity = error
# VSTHRD100: Avoid async void methods
dotnet_diagnostic.VSTHRD100.severity = error
# VSTHRD101: Avoid unsupported async delegates
dotnet_diagnostic.VSTHRD101.severity = error
# VSTHRD107: Await Task within using expression
dotnet_diagnostic.VSTHRD107.severity = error
# AsyncFixer04: Fire & forget async call inside a using block
dotnet_diagnostic.AsyncFixer04.severity = error
# VSTHRD110: Observe result of async calls
dotnet_diagnostic.VSTHRD110.severity = error
# VSTHRD002: Avoid problematic synchronous waits
dotnet_diagnostic.VSTHRD002.severity = suggestion
# MA0045: Do not use blocking call (make method async)
dotnet_diagnostic.MA0045.severity = suggestion
# AsyncifyInvocation: Use Task Async
dotnet_diagnostic.AsyncifyInvocation.severity = error
# AsyncifyVariable: Use Task Async
dotnet_diagnostic.AsyncifyVariable.severity = error
# VSTHRD111: Use ConfigureAwait(bool)
dotnet_diagnostic.VSTHRD111.severity = suggestion
# MA0022: Return Task.FromResult instead of returning null
dotnet_diagnostic.MA0022.severity = error
# VSTHRD114: Avoid returning a null Task
dotnet_diagnostic.VSTHRD114.severity = error
# VSTHRD200: Use "Async" suffix for async methods
dotnet_diagnostic.VSTHRD200.severity = suggestion
# MA0040: Specify a cancellation token
dotnet_diagnostic.MA0032.severity = suggestion
# MA0040: Flow the cancellation token when available
dotnet_diagnostic.MA0040.severity = suggestion
# MA0079: Use a cancellation token using .WithCancellation()
dotnet_diagnostic.MA0079.severity = suggestion
# MA0080: Use a cancellation token using .WithCancellation()
dotnet_diagnostic.MA0080.severity = error
#AsyncFixer05: Downcasting from a nested task to an outer task.
dotnet_diagnostic.AsyncFixer05.severity = error
# ClrHeapAllocationAnalyzer ----------------------------------------------------
# HAA0301: Closure Allocation Source
dotnet_diagnostic.HAA0301.severity = suggestion
# HAA0601: Value type to reference type conversion causing boxing allocation
dotnet_diagnostic.HAA0601.severity = suggestion
# HAA0302: Display class allocation to capture closure
dotnet_diagnostic.HAA0302.severity = suggestion
# HAA0101: Array allocation for params parameter
dotnet_diagnostic.HAA0101.severity = suggestion
# HAA0603: Delegate allocation from a method group
dotnet_diagnostic.HAA0603.severity = suggestion
# HAA0602: Delegate on struct instance caused a boxing allocation
dotnet_diagnostic.HAA0602.severity = suggestion
# HAA0401: Possible allocation of reference type enumerator
dotnet_diagnostic.HAA0401.severity = suggestion
# HAA0303: Lambda or anonymous method in a generic method allocates a delegate instance
dotnet_diagnostic.HAA0303.severity = suggestion
# HAA0102: Non-overridden virtual method call on value type
dotnet_diagnostic.HAA0102.severity = suggestion
# HAA0502: Explicit new reference type allocation
dotnet_diagnostic.HAA0502.severity = suggestion
# HAA0505: Initializer reference type allocation
dotnet_diagnostic.HAA0505.severity = suggestion
# Sonar --------------------------------------------------
# S125: Sections of code should not be commented out
dotnet_diagnostic.S125.severity = suggestion
# S1481: Unused local variables should be removed
dotnet_diagnostic.S1481.severity = suggestion
# MA -----------------------------------------------------
MA0051.maximum_lines_per_method = 80
MA0051.maximum_statements_per_method = 60
MA0011.exclude_tostring_methods=true
dotnet_diagnostic.MA0011.severity = suggestion
dotnet_diagnostic.MA0048.severity = suggestion
dotnet_diagnostic.MA0016.severity = suggestion