Skip to content

Commit 701d16f

Browse files
feat: this commit introduces .editorconfig to enforce coding styles and rules for csharp and json files
1 parent 8579a6d commit 701d16f

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

.editorconfig

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 4
6+
trim_trailing_whitespace = true
7+
insert_final_newline = true
8+
end_of_line = crlf
9+
10+
[*.cs]
11+
dotnet_diagnostic.IDE0055.severity = error
12+
dotnet_diagnostic.IDE0029.severity = error
13+
dotnet_diagnostic.IDE0051.severity = error
14+
dotnet_diagnostic.IDE0059.severity = error
15+
dotnet_diagnostic.IDE0060.severity = error
16+
dotnet_diagnostic.IDE0074.severity = error
17+
dotnet_diagnostic.IDE2000.severity = error
18+
dotnet_diagnostic.IDE2001.severity = error
19+
dotnet_diagnostic.IDE2002.severity = error
20+
21+
# unnecessary usings (https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0005)
22+
dotnet_diagnostic.IDE0005.severity = error
23+
24+
# unused variables (https://learn.microsoft.com/en-us/dotnet/csharp/misc/cs0168)
25+
dotnet_diagnostic.CS0168.severity = error
26+
27+
# assigned but never used (https://learn.microsoft.com/en-us/dotnet/csharp/misc/cs0219)
28+
dotnet_diagnostic.CS0219.severity = error
29+
30+
[*.json]
31+
indent_style = space
32+
indent_size = 4
33+
trim_trailing_whitespace = true
34+
35+
[*.{cs,json}]
36+
trim_trailing_whitespace = true

0 commit comments

Comments
 (0)