Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Altinn3.ruleset with .editorconfig #100

Merged
merged 1 commit into from
Oct 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
288 changes: 288 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,288 @@
# Remove the line below if you want to inherit .editorconfig settings from higher directories
root = true

#### Naming styles ####

[*.cs]
# Naming rules

dotnet_naming_rule.private_or_internal_field_should_be_begins_with__.severity = suggestion
dotnet_naming_rule.private_or_internal_field_should_be_begins_with__.symbols = private_or_internal_field
dotnet_naming_rule.private_or_internal_field_should_be_begins_with__.style = begins_with__

# Symbol specifications

dotnet_naming_symbols.private_or_internal_field.applicable_kinds = field
dotnet_naming_symbols.private_or_internal_field.applicable_accessibilities = internal, private, private_protected
dotnet_naming_symbols.private_or_internal_field.required_modifiers =

# Naming styles

dotnet_naming_style.begins_with__.required_prefix = _
dotnet_naming_style.begins_with__.required_suffix =
dotnet_naming_style.begins_with__.word_separator =
dotnet_naming_style.begins_with__.capitalization = camel_case
csharp_indent_labels = one_less_than_current
csharp_using_directive_placement = outside_namespace:warning
csharp_prefer_simple_using_statement = true:suggestion
csharp_prefer_braces = true:silent
csharp_style_namespace_declarations = block_scoped:silent
csharp_style_prefer_method_group_conversion = true:silent
csharp_style_prefer_top_level_statements = true:silent
csharp_style_expression_bodied_methods = false:silent
csharp_style_expression_bodied_constructors = false:silent
csharp_style_expression_bodied_operators = false:silent
csharp_style_expression_bodied_properties = true:silent
csharp_style_expression_bodied_indexers = true:silent
csharp_style_expression_bodied_accessors = true:silent
csharp_style_expression_bodied_lambdas = true:silent
csharp_style_expression_bodied_local_functions = false:silent
csharp_style_throw_expression = true:suggestion
csharp_style_prefer_null_check_over_type_check = true:suggestion
csharp_prefer_simple_default_expression = true:suggestion
csharp_space_around_binary_operators = before_and_after
csharp_style_prefer_primary_constructors = true:suggestion

[*.{cs,vb}]
#### Naming styles ####

# Naming rules

dotnet_naming_rule.interface_should_be_begins_with_i.severity = suggestion
dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface
dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i

dotnet_naming_rule.types_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.types_should_be_pascal_case.symbols = types
dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case

dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members
dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case

# Symbol specifications

dotnet_naming_symbols.interface.applicable_kinds = interface
dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.interface.required_modifiers =

dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum
dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.types.required_modifiers =

dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method
dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.non_field_members.required_modifiers =

# Naming styles

dotnet_naming_style.begins_with_i.required_prefix = I
dotnet_naming_style.begins_with_i.required_suffix =
dotnet_naming_style.begins_with_i.word_separator =
dotnet_naming_style.begins_with_i.capitalization = pascal_case

dotnet_naming_style.pascal_case.required_prefix =
dotnet_naming_style.pascal_case.required_suffix =
dotnet_naming_style.pascal_case.word_separator =
dotnet_naming_style.pascal_case.capitalization = pascal_case

dotnet_naming_style.pascal_case.required_prefix =
dotnet_naming_style.pascal_case.required_suffix =
dotnet_naming_style.pascal_case.word_separator =
dotnet_naming_style.pascal_case.capitalization = pascal_case
dotnet_style_operator_placement_when_wrapping = beginning_of_line
tab_width = 4
indent_size = 4
end_of_line = crlf
dotnet_style_coalesce_expression = true:suggestion
dotnet_style_null_propagation = true:suggestion
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion
dotnet_style_prefer_auto_properties = true:silent
dotnet_style_object_initializer = true:suggestion
dotnet_style_collection_initializer = true:suggestion
dotnet_style_prefer_simplified_boolean_expressions = true:suggestion
dotnet_style_prefer_conditional_expression_over_assignment = true:silent
dotnet_style_prefer_conditional_expression_over_return = true:silent
dotnet_style_explicit_tuple_names = true:suggestion
dotnet_style_prefer_inferred_tuple_names = true:suggestion
dotnet_style_prefer_inferred_anonymous_type_member_names = true:suggestion
dotnet_style_prefer_compound_assignment = true:suggestion
dotnet_style_prefer_simplified_interpolation = true:suggestion
dotnet_style_namespace_match_folder = true:suggestion

# StyleCop.Analyzers
[*.{cs,vb}]

dotnet_diagnostic.SA0001.severity = error
dotnet_diagnostic.SA0002.severity = none
dotnet_diagnostic.SA1000.severity = warning
dotnet_diagnostic.SA1001.severity = warning
dotnet_diagnostic.SA1002.severity = warning
dotnet_diagnostic.SA1003.severity = warning
dotnet_diagnostic.SA1004.severity = warning
dotnet_diagnostic.SA1005.severity = warning
dotnet_diagnostic.SA1006.severity = warning
dotnet_diagnostic.SA1007.severity = warning
dotnet_diagnostic.SA1008.severity = warning
dotnet_diagnostic.SA1009.severity = warning
dotnet_diagnostic.SA1010.severity = warning
dotnet_diagnostic.SA1011.severity = warning
dotnet_diagnostic.SA1012.severity = warning
dotnet_diagnostic.SA1013.severity = warning
dotnet_diagnostic.SA1014.severity = warning
dotnet_diagnostic.SA1015.severity = warning
dotnet_diagnostic.SA1016.severity = warning
dotnet_diagnostic.SA1017.severity = warning
dotnet_diagnostic.SA1018.severity = warning
dotnet_diagnostic.SA1019.severity = warning
dotnet_diagnostic.SA1020.severity = warning
dotnet_diagnostic.SA1021.severity = warning
dotnet_diagnostic.SA1022.severity = warning
dotnet_diagnostic.SA1023.severity = warning
dotnet_diagnostic.SA1024.severity = none
dotnet_diagnostic.SA1025.severity = warning
dotnet_diagnostic.SA1026.severity = warning
dotnet_diagnostic.SA1027.severity = warning
dotnet_diagnostic.SA1028.severity = none
dotnet_diagnostic.SA1100.severity = error
dotnet_diagnostic.SA1101.severity = none
dotnet_diagnostic.SA1102.severity = error
dotnet_diagnostic.SA1103.severity = error
dotnet_diagnostic.SA1104.severity = error
dotnet_diagnostic.SA1105.severity = error
dotnet_diagnostic.SA1106.severity = error
dotnet_diagnostic.SA1107.severity = error
dotnet_diagnostic.SA1108.severity = error
dotnet_diagnostic.SA1110.severity = error
dotnet_diagnostic.SA1111.severity = error
dotnet_diagnostic.SA1112.severity = error
dotnet_diagnostic.SA1113.severity = error
dotnet_diagnostic.SA1114.severity = error
dotnet_diagnostic.SA1115.severity = error
dotnet_diagnostic.SA1116.severity = error
dotnet_diagnostic.SA1117.severity = error
dotnet_diagnostic.SA1118.severity = error
dotnet_diagnostic.SA1119.severity = error
dotnet_diagnostic.SA1120.severity = error
dotnet_diagnostic.SA1121.severity = error
dotnet_diagnostic.SA1122.severity = error
dotnet_diagnostic.SA1123.severity = none
dotnet_diagnostic.SA1124.severity = none
dotnet_diagnostic.SA1125.severity = error
dotnet_diagnostic.SA1127.severity = error
dotnet_diagnostic.SA1128.severity = none
dotnet_diagnostic.SA1129.severity = error
dotnet_diagnostic.SA1130.severity = error
dotnet_diagnostic.SA1131.severity = error
dotnet_diagnostic.SA1132.severity = error
dotnet_diagnostic.SA1133.severity = error
dotnet_diagnostic.SA1134.severity = error
dotnet_diagnostic.SA1135.severity = error
dotnet_diagnostic.SA1136.severity = error
dotnet_diagnostic.SA1137.severity = warning
dotnet_diagnostic.SA1139.severity = none
dotnet_diagnostic.SA1200.severity = none
dotnet_diagnostic.SA1201.severity = none
dotnet_diagnostic.SA1202.severity = none
dotnet_diagnostic.SA1203.severity = none
dotnet_diagnostic.SA1204.severity = none
dotnet_diagnostic.SA1205.severity = none
dotnet_diagnostic.SA1206.severity = none
dotnet_diagnostic.SA1207.severity = none
dotnet_diagnostic.SA1208.severity = error
dotnet_diagnostic.SA1209.severity = error
dotnet_diagnostic.SA1210.severity = error
dotnet_diagnostic.SA1211.severity = error
dotnet_diagnostic.SA1212.severity = none
dotnet_diagnostic.SA1213.severity = none
dotnet_diagnostic.SA1214.severity = none
dotnet_diagnostic.SA1216.severity = error
dotnet_diagnostic.SA1217.severity = error
dotnet_diagnostic.SA1300.severity = error
dotnet_diagnostic.SA1302.severity = error
dotnet_diagnostic.SA1303.severity = error
dotnet_diagnostic.SA1304.severity = error
dotnet_diagnostic.SA1305.severity = error
dotnet_diagnostic.SA1306.severity = error
dotnet_diagnostic.SA1307.severity = error
dotnet_diagnostic.SA1308.severity = error
dotnet_diagnostic.SA1309.severity = none
dotnet_diagnostic.SA1310.severity = none
dotnet_diagnostic.SA1311.severity = error
dotnet_diagnostic.SA1312.severity = error
dotnet_diagnostic.SA1313.severity = none
dotnet_diagnostic.SA1314.severity = error
dotnet_diagnostic.SA1400.severity = warning
dotnet_diagnostic.SA1401.severity = error
dotnet_diagnostic.SA1402.severity = none
dotnet_diagnostic.SA1403.severity = error
dotnet_diagnostic.SA1404.severity = error
dotnet_diagnostic.SA1405.severity = none
dotnet_diagnostic.SA1406.severity = none
dotnet_diagnostic.SA1407.severity = error
dotnet_diagnostic.SA1408.severity = error
dotnet_diagnostic.SA1410.severity = none
dotnet_diagnostic.SA1411.severity = none
dotnet_diagnostic.SA1413.severity = none
dotnet_diagnostic.SA1500.severity = error
dotnet_diagnostic.SA1501.severity = error
dotnet_diagnostic.SA1502.severity = error
dotnet_diagnostic.SA1503.severity = error
dotnet_diagnostic.SA1504.severity = error
dotnet_diagnostic.SA1505.severity = error
dotnet_diagnostic.SA1506.severity = error
dotnet_diagnostic.SA1507.severity = error
dotnet_diagnostic.SA1508.severity = warning
dotnet_diagnostic.SA1509.severity = warning
dotnet_diagnostic.SA1510.severity = error
dotnet_diagnostic.SA1511.severity = error
dotnet_diagnostic.SA1512.severity = warning
dotnet_diagnostic.SA1513.severity = error
dotnet_diagnostic.SA1514.severity = error
dotnet_diagnostic.SA1515.severity = error
dotnet_diagnostic.SA1516.severity = error
dotnet_diagnostic.SA1517.severity = error
dotnet_diagnostic.SA1518.severity = error
dotnet_diagnostic.SA1519.severity = error
dotnet_diagnostic.SA1520.severity = error
dotnet_diagnostic.SA1600.severity = error
dotnet_diagnostic.SA1601.severity = error
dotnet_diagnostic.SA1602.severity = none
dotnet_diagnostic.SA1604.severity = error
dotnet_diagnostic.SA1605.severity = error
dotnet_diagnostic.SA1606.severity = error
dotnet_diagnostic.SA1607.severity = error
dotnet_diagnostic.SA1608.severity = error
dotnet_diagnostic.SA1610.severity = error
dotnet_diagnostic.SA1611.severity = none
dotnet_diagnostic.SA1612.severity = error
dotnet_diagnostic.SA1613.severity = error
dotnet_diagnostic.SA1614.severity = error
dotnet_diagnostic.SA1615.severity = none
dotnet_diagnostic.SA1616.severity = none
dotnet_diagnostic.SA1617.severity = error
dotnet_diagnostic.SA1618.severity = none
dotnet_diagnostic.SA1619.severity = none
dotnet_diagnostic.SA1620.severity = none
dotnet_diagnostic.SA1621.severity = error
dotnet_diagnostic.SA1622.severity = none
dotnet_diagnostic.SA1623.severity = none
dotnet_diagnostic.SA1624.severity = error
dotnet_diagnostic.SA1625.severity = error
dotnet_diagnostic.SA1626.severity = warning
dotnet_diagnostic.SA1627.severity = error
dotnet_diagnostic.SA1629.severity = none
dotnet_diagnostic.SA1633.severity = none
dotnet_diagnostic.SA1634.severity = none
dotnet_diagnostic.SA1635.severity = none
dotnet_diagnostic.SA1636.severity = none
dotnet_diagnostic.SA1637.severity = none
dotnet_diagnostic.SA1638.severity = none
dotnet_diagnostic.SA1640.severity = none
dotnet_diagnostic.SA1641.severity = none
dotnet_diagnostic.SA1642.severity = none
dotnet_diagnostic.SA1643.severity = none
dotnet_diagnostic.SA1648.severity = error
dotnet_diagnostic.SA1649.severity = error
dotnet_diagnostic.SA1651.severity = error
insert_final_newline = true
12 changes: 6 additions & 6 deletions Altinn.Profile.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.32014.148
MinimumVisualStudioVersion = 10.0.40219.1
Project("{E53339B2-1760-4266-BCC7-CA923CBCF16C}") = "docker-compose", "docker-compose.dcproj", "{DFD11A0E-FC6D-4979-87A4-7A7B5DC66695}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Altinn.Profile", "src\Altinn.Profile\Altinn.Profile.csproj", "{D32C4EE9-E827-467A-B116-8EF0BA08A11F}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Altinn.Profile.Tests", "test\Altinn.Profile.Tests\Altinn.Profile.Tests.csproj", "{85BF7FD9-90C1-4A4E-BDCC-F89F0BA65218}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution items", "Solution items", "{132B1657-0A2D-4047-8F3F-28C0004C011E}"
ProjectSection(SolutionItems) = preProject
Dockerfile = Dockerfile
README.md = README.md
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{DFD11A0E-FC6D-4979-87A4-7A7B5DC66695}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DFD11A0E-FC6D-4979-87A4-7A7B5DC66695}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DFD11A0E-FC6D-4979-87A4-7A7B5DC66695}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DFD11A0E-FC6D-4979-87A4-7A7B5DC66695}.Release|Any CPU.Build.0 = Release|Any CPU
{D32C4EE9-E827-467A-B116-8EF0BA08A11F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D32C4EE9-E827-467A-B116-8EF0BA08A11F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D32C4EE9-E827-467A-B116-8EF0BA08A11F}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down
Loading
Loading