Skip to content

Commit b5df63c

Browse files
committed
- Fix Lint issues
1 parent 759fe8f commit b5df63c

File tree

4 files changed

+119
-3
lines changed

4 files changed

+119
-3
lines changed

.editorconfig

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
# EditorConfig is awesome: https://EditorConfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
# All files
7+
[*]
8+
charset = utf-8
9+
end_of_line = lf
10+
insert_final_newline = true
11+
trim_trailing_whitespace = true
12+
13+
# Code files
14+
[*.{cs,csx,vb,vbx}]
15+
indent_size = 4
16+
indent_style = space
17+
tab_width = 4
18+
19+
# XML project files
20+
[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}]
21+
indent_size = 2
22+
23+
# XML config files
24+
[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}]
25+
indent_size = 2
26+
27+
# JSON files
28+
[*.json]
29+
indent_size = 2
30+
31+
# YAML files
32+
[*.{yml,yaml}]
33+
indent_size = 2
34+
35+
# Markdown files
36+
[*.md]
37+
trim_trailing_whitespace = false
38+
39+
# Dotnet code style settings:
40+
[*.{cs,vb}]
41+
# Sort using and Import directives with System.* appearing first
42+
dotnet_sort_system_directives_first = true
43+
dotnet_separate_import_directive_groups = false
44+
45+
# Avoid "this." and "Me." if not necessary
46+
dotnet_style_qualification_for_field = false:refactoring
47+
dotnet_style_qualification_for_property = false:refactoring
48+
dotnet_style_qualification_for_method = false:refactoring
49+
dotnet_style_qualification_for_event = false:refactoring
50+
51+
# Use language keywords instead of framework type names for type references
52+
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
53+
dotnet_style_predefined_type_for_member_access = true:suggestion
54+
55+
# Suggest more modern language features when available
56+
dotnet_style_object_initializer = true:suggestion
57+
dotnet_style_collection_initializer = true:suggestion
58+
dotnet_style_coalesce_expression = true:suggestion
59+
dotnet_style_null_propagation = true:suggestion
60+
dotnet_style_explicit_tuple_names = true:suggestion
61+
62+
# CSharp code style settings:
63+
[*.cs]
64+
# Newline settings
65+
csharp_new_line_before_open_brace = all
66+
csharp_new_line_before_else = true
67+
csharp_new_line_before_catch = true
68+
csharp_new_line_before_finally = true
69+
csharp_new_line_before_members_in_object_initializers = true
70+
csharp_new_line_before_members_in_anonymous_types = true
71+
csharp_new_line_between_query_expression_clauses = true
72+
73+
# Indentation preferences
74+
csharp_indent_case_contents = true
75+
csharp_indent_switch_labels = true
76+
csharp_indent_labels = flush_left
77+
csharp_indent_block_contents = true
78+
csharp_indent_braces = false
79+
80+
# Space preferences
81+
csharp_space_after_cast = false
82+
csharp_space_after_keywords_in_control_flow_statements = true
83+
csharp_space_between_method_call_parameter_list_parentheses = false
84+
csharp_space_between_method_declaration_parameter_list_parentheses = false
85+
csharp_space_between_parentheses = false
86+
csharp_space_before_colon_in_inheritance_clause = true
87+
csharp_space_after_colon_in_inheritance_clause = true
88+
csharp_space_around_binary_operators = before_and_after
89+
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
90+
csharp_space_between_method_call_name_and_opening_parenthesis = false
91+
csharp_space_between_method_call_empty_parameter_list_parentheses = false
92+
93+
# Prefer "var" everywhere
94+
csharp_style_var_for_built_in_types = false:silent
95+
csharp_style_var_when_type_is_apparent = true:suggestion
96+
csharp_style_var_elsewhere = false:silent
97+
98+
# Prefer method-like constructs to have a block body
99+
csharp_style_expression_bodied_methods = false:none
100+
csharp_style_expression_bodied_constructors = false:none
101+
csharp_style_expression_bodied_operators = false:none
102+
103+
# Prefer property-like constructs to have an expression-body
104+
csharp_style_expression_bodied_properties = true:none
105+
csharp_style_expression_bodied_indexers = true:none
106+
csharp_style_expression_bodied_accessors = true:none
107+
108+
# Suggest more modern language features when available
109+
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
110+
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
111+
csharp_style_inlined_variable_declaration = true:suggestion
112+
csharp_style_throw_expression = true:suggestion
113+
csharp_style_conditional_delegate_call = true:suggestion
114+
115+
# Code quality
116+
dotnet_code_quality_unused_parameters = all:suggestion

src/SourceFlow/SourceFlow.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFrameworks>net462;netstandard2.0;netstandard2.1;net9.0;net10.0</TargetFrameworks>

tests/SourceFlow.Core.Tests/SourceFlow.Core.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFramework>net9.0</TargetFramework>

tests/SourceFlow.Net.EntityFramework.Tests/SourceFlow.Stores.EntityFramework.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
44
<TargetFramework>net9.0</TargetFramework>

0 commit comments

Comments
 (0)