Skip to content
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
176 changes: 176 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,176 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

# Default: prefer spaces for data/markup
indent_style = space
indent_size = 2
tab_width = 2

# This style rule concern the use of the range operator, which is available in C# 8.0 and later.
# https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0057
[*.{cs,vb}]
dotnet_diagnostic.IDE0057.severity = none

# This style rule concerns the use of switch expressions versus switch statements.
# https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0066
[*.{cs,vb}]
dotnet_diagnostic.IDE0066.severity = none

# Performance rules
# https://docs.microsoft.com/da-dk/dotnet/fundamentals/code-analysis/quality-rules/performance-warnings
[*.{cs,vb}]
dotnet_analyzer_diagnostic.category-Performance.severity = none # Because many of the suggestions by performance analyzers are not compatible with .NET Standard 2.0

# This style rule concerns the use of using statements without curly braces, also known as using declarations. This alternative syntax was introduced in C# 8.0.
# https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0063
[*.{cs,vb}]
dotnet_diagnostic.IDE0063.severity = none

# This style rule concerns with simplification of interpolated strings to improve code readability. It recommends removal of certain explicit method calls, such as ToString(), when the same method would be implicitly invoked by the compiler if the explicit method call is removed.
# https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0071
[*.{cs,vb}]
dotnet_diagnostic.IDE0071.severity = none

# S3267: Loops should be simplified with "LINQ" expressions
# https://rules.sonarsource.com/csharp/RSPEC-3267
dotnet_diagnostic.S3267.severity = none

# CA1859: Use concrete types when possible for improved performance
# This is a violation of Framework Design Guidelines.
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1859
[*.{cs,vb}]
dotnet_diagnostic.CA1859.severity = none

# IDE0008: Use explicit type
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0007-ide0008
[*.{cs,vb}]
dotnet_diagnostic.IDE0008.severity = none

[*.{cs,vb}]
indent_style = space
indent_size = 4

# IDE0161: Namespace declaration preferences
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0161
# Prefer file-scoped namespaces for new files; existing block-scoped files should not be converted unless explicitly asked
[*.cs]
csharp_style_namespace_declarations = file_scoped:suggestion

# Top-level statements: DO NOT USE
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0210-ide0211
# This is enforced via a style preference set to error severity, not a language-level prohibition.
# Always use explicit class declarations with a proper namespace and Main method where applicable.
[*.cs]
csharp_style_prefer_top_level_statements = false:error

[*.xml]
indent_style = space
indent_size = 2

# IDE0078: Use pattern matching
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0078
[*.{cs,vb}]
dotnet_diagnostic.IDE0078.severity = none

# IDE0290: Use primary constructor
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0290
[*.{cs,vb}]
dotnet_diagnostic.IDE0290.severity = none

# IDE0305: Use collection expression for fluent
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0305
[*.{cs,vb}]
dotnet_diagnostic.IDE0305.severity = none

# IDE0011: Add braces
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0011
[*.{cs,vb}]
dotnet_diagnostic.IDE0011.severity = none

# IDE0028: Use collection initializers or expressions
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0028
[*.{cs,vb}]
dotnet_diagnostic.IDE0028.severity = none

# IDE0039: Use collection expression for array
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0300
[*.{cs,vb}]
dotnet_diagnostic.IDE0300.severity = none

# IDE0031: Use collection expression for empty
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0301
[*.{cs,vb}]
dotnet_diagnostic.IDE0301.severity = none

# IDE0046: Use conditional expression for return
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0046
[*.{cs,vb}]
dotnet_diagnostic.IDE0046.severity = none

# IDE0047: Parentheses preferences
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0047-ide0048
[*.{cs,vb}]
dotnet_diagnostic.IDE0047.severity = none

# CA1716: Identifiers should not match keywords
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1716
[*.{cs,vb}]
dotnet_diagnostic.CA1716.severity = none

# CA1720: Identifiers should not contain type names
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1720
[*.{cs,vb}]
dotnet_diagnostic.CA1720.severity = none

# CA1846: Prefer AsSpan over Substring
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1846
# Excluded while TFMs include netstandard2.0
[*.{cs,vb}]
dotnet_diagnostic.CA1846.severity = none

# CA1847: Use String.Contains(char) instead of String.Contains(string) with single characters
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1847
# Excluded while TFMs include netstandard2.0
[*.{cs,vb}]
dotnet_diagnostic.CA1847.severity = none

# CA1865-CA1867: Use 'string.Method(char)' instead of 'string.Method(string)' for string with single char
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca1865-ca1867
# Excluded while TFMs include netstandard2.0
[*.{cs,vb}]
dotnet_diagnostic.CA1865.severity = none
dotnet_diagnostic.CA1866.severity = none
dotnet_diagnostic.CA1867.severity = none

# CA2263: Prefer generic overload when type is known
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca2263
# Excluded while TFMs include netstandard2.0
[*.{cs,vb}]
dotnet_diagnostic.CA2263.severity = none

# CA2249: Consider using String.Contains instead of String.IndexOf
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca2249
# Excluded while TFMs include netstandard2.0
[*.{cs,vb}]
dotnet_diagnostic.CA2249.severity = none

# IDE0022: Use expression body for methods
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0022
[*.{cs,vb}]
dotnet_diagnostic.IDE0022.severity = none

# IDE0032: Use auto-property
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0032
[*.{cs,vb}]
dotnet_diagnostic.IDE0032.severity = none

# Order modifiers
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/style-rules/ide0036
# Excluded becuase of inconsistency with other analyzers
[*.{cs,vb}]
dotnet_diagnostic.IDE0036.severity = none
63 changes: 63 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
###############################################################################
# Set default behavior to automatically normalize line endings.
###############################################################################
* text=auto

###############################################################################
# Set default behavior for command prompt diff.
#
# This is need for earlier builds of msysgit that does not have it on by
# default for csharp files.
# Note: This is only used by command line
###############################################################################
#*.cs diff=csharp

###############################################################################
# Set the merge driver for project and solution files
#
# Merging from the command prompt will add diff markers to the files if there
# are conflicts (Merging from VS is not affected by the settings below, in VS
# the diff markers are never inserted). Diff markers may cause the following
# file extensions to fail to load in VS. An alternative would be to treat
# these files as binary and thus will always conflict and require user
# intervention with every merge. To do so, just uncomment the entries below
###############################################################################
#*.sln merge=binary
#*.csproj merge=binary
#*.vbproj merge=binary
#*.vcxproj merge=binary
#*.vcproj merge=binary
#*.dbproj merge=binary
#*.fsproj merge=binary
#*.lsproj merge=binary
#*.wixproj merge=binary
#*.modelproj merge=binary
#*.sqlproj merge=binary
#*.wwaproj merge=binary

###############################################################################
# behavior for image files
#
# image files are treated as binary by default.
###############################################################################
#*.jpg binary
#*.png binary
#*.gif binary

###############################################################################
# diff behavior for common document formats
#
# Convert binary document formats to text before diffing them. This feature
# is only available from the command line. Turn it on by uncommenting the
# entries below.
###############################################################################
#*.doc diff=astextplain
#*.DOC diff=astextplain
#*.docx diff=astextplain
#*.DOCX diff=astextplain
#*.dot diff=astextplain
#*.DOT diff=astextplain
#*.pdf diff=astextplain
#*.PDF diff=astextplain
#*.rtf diff=astextplain
#*.RTF diff=astextplain
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
Version: 10.2.3
Availability: .NET 10 and .NET 9

# ALM
- CHANGED Dependencies have been upgraded to the latest compatible versions for all supported target frameworks (TFMs)

Version: 10.2.2
Availability: .NET 10 and .NET 9

Expand Down
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,21 @@ For more details, please refer to `PackageReleaseNotes.txt` on a per assembly ba
> [!NOTE]
> Changelog entries prior to version 8.4.0 was migrated from previous versions of Cuemon.Extensions.Asp.Versioning.

## [10.2.3] - 2026-08-16

This is a patch release focused on package dependencies, development infrastructure improvements, and project-level configuration standardization. The release upgrades core dependencies to their latest compatible versions, introduces project-level code style enforcement and Git behavior configuration, and consolidates Docker test environments for simplified multi-framework testing.

### Added

- `.editorconfig` for project-level code style enforcement with UTF-8 encoding, indentation rules, and analyzer suppressions,
- `.gitattributes` for Git behavior configuration with line ending normalization and merge strategy standardization.

### Changed

- Dependencies upgraded to latest compatible versions: Codebelt.Extensions.AspNetCore.Mvc.Formatters.Newtonsoft.Json (10.1.6 → 10.1.7), Codebelt.Extensions.Xunit.App (11.1.2 → 11.2.1), Cuemon.AspNetCore and related packages (10.5.5 → 10.7.0), and Microsoft.NET.Test.Sdk (18.8.1 → 18.9.0),
- Asp.Versioning packages for .NET 10 targets upgraded from 10.0.0 to 10.2.x series: Abstractions and Mvc to 10.2.1, Http to 10.2.2, and Mvc.ApiExplorer to 10.2.1,
- Docker test environments consolidated from separate net9 and net10 images to single multi-version `codebeltnet/ubuntu-testrunner:8-9-10-11` image for simplified test infrastructure.

## [10.2.2] - 2026-07-24

This is a patch release focused on dependency updates, build toolchain improvements, and documentation quality. The release upgrades core development dependencies to their latest stable patches, enables recommended .NET code analyzers with code style enforcement, configures consistent git tag naming, and refines XML documentation.
Expand Down Expand Up @@ -208,6 +223,7 @@ This major release is first and foremost focused on ironing out any wrinkles tha
- RestfulApiVersionReader class in the Codebelt.Extensions.Asp.Versioning namespace that represents a RESTful API version reader that reads the value from a filtered list of HTTP Accept headers in the request
- RestfulProblemDetailsFactory class in the Codebelt.Extensions.Asp.Versioning namespace that represents a RESTful implementation of the IProblemDetailsFactory which throws variants of HttpStatusCodeException that needs to be translated accordingly

[10.2.3]: https://github.com/codebeltnet/asp-versioning/compare/v10.2.2...v10.2.3
[10.2.2]: https://github.com/codebeltnet/asp-versioning/compare/v10.2.1...v10.2.2
[10.2.1]: https://github.com/codebeltnet/asp-versioning/compare/v10.2.0...v10.2.1
[10.2.0]: https://github.com/codebeltnet/asp-versioning/compare/v10.1.0...v10.2.0
Expand Down
64 changes: 32 additions & 32 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,33 +1,33 @@
<Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="Codebelt.Extensions.AspNetCore.Mvc.Formatters.Newtonsoft.Json" Version="10.1.6" />
<PackageVersion Include="Codebelt.Extensions.AspNetCore.Mvc.Formatters.Text.Yaml" Version="10.1.6" />
<PackageVersion Include="Codebelt.Extensions.Xunit.App" Version="11.1.2" />
<PackageVersion Include="Cuemon.AspNetCore" Version="10.5.5" />
<PackageVersion Include="Cuemon.Extensions.AspNetCore.Mvc" Version="10.5.5" />
<PackageVersion Include="Cuemon.Extensions.AspNetCore.Mvc.Formatters.Text.Json" Version="10.5.5" />
<PackageVersion Include="Cuemon.Extensions.AspNetCore.Mvc.Formatters.Xml" Version="10.5.5" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="18.8.1" />
<PackageVersion Include="MinVer" Version="7.0.0" />
<PackageVersion Include="coverlet.collector" Version="10.0.1" />
<PackageVersion Include="coverlet.msbuild" Version="10.0.1" />
<PackageVersion Include="xunit.v3" Version="3.2.2" />
<PackageVersion Include="xunit.v3.runner.console" Version="3.2.2" />
<PackageVersion Include="xunit.runner.visualstudio" Version="3.1.5" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net9'))">
<PackageVersion Include="Asp.Versioning.Abstractions" Version="8.1.0" />
<PackageVersion Include="Asp.Versioning.Http" Version="8.1.1" />
<PackageVersion Include="Asp.Versioning.Mvc" Version="8.1.1" />
<PackageVersion Include="Asp.Versioning.Mvc.ApiExplorer" Version="8.1.1" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net10'))">
<PackageVersion Include="Asp.Versioning.Abstractions" Version="10.0.0" />
<PackageVersion Include="Asp.Versioning.Http" Version="10.0.0" />
<PackageVersion Include="Asp.Versioning.Mvc" Version="10.0.0" />
<PackageVersion Include="Asp.Versioning.Mvc.ApiExplorer" Version="10.0.0" />
</ItemGroup>
<Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="Codebelt.Extensions.AspNetCore.Mvc.Formatters.Newtonsoft.Json" Version="10.1.7" />
<PackageVersion Include="Codebelt.Extensions.AspNetCore.Mvc.Formatters.Text.Yaml" Version="10.1.6" />
<PackageVersion Include="Codebelt.Extensions.Xunit.App" Version="11.2.1" />
<PackageVersion Include="Cuemon.AspNetCore" Version="10.7.0" />
<PackageVersion Include="Cuemon.Extensions.AspNetCore.Mvc" Version="10.7.0" />
<PackageVersion Include="Cuemon.Extensions.AspNetCore.Mvc.Formatters.Text.Json" Version="10.7.0" />
<PackageVersion Include="Cuemon.Extensions.AspNetCore.Mvc.Formatters.Xml" Version="10.7.0" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="18.9.0" />
<PackageVersion Include="MinVer" Version="7.0.0" />
<PackageVersion Include="coverlet.collector" Version="10.0.1" />
<PackageVersion Include="coverlet.msbuild" Version="10.0.1" />
<PackageVersion Include="xunit.v3" Version="3.2.2" />
<PackageVersion Include="xunit.v3.runner.console" Version="3.2.2" />
<PackageVersion Include="xunit.runner.visualstudio" Version="3.1.5" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net9'))">
<PackageVersion Include="Asp.Versioning.Abstractions" Version="8.1.0" />
<PackageVersion Include="Asp.Versioning.Http" Version="8.1.1" />
<PackageVersion Include="Asp.Versioning.Mvc" Version="8.1.1" />
<PackageVersion Include="Asp.Versioning.Mvc.ApiExplorer" Version="8.1.1" />
</ItemGroup>
<ItemGroup Condition="$(TargetFramework.StartsWith('net10'))">
<PackageVersion Include="Asp.Versioning.Abstractions" Version="10.2.1" />
<PackageVersion Include="Asp.Versioning.Http" Version="10.2.2" />
<PackageVersion Include="Asp.Versioning.Mvc" Version="10.2.1" />
<PackageVersion Include="Asp.Versioning.Mvc.ApiExplorer" Version="10.2.1" />
</ItemGroup>
</Project>
9 changes: 2 additions & 7 deletions testenvironments.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,9 @@
"wslDistribution": "Ubuntu-24.04"
},
{
"name": "Docker-Ubuntu (net9)",
"name": "Docker-Ubuntu",
"type": "docker",
"dockerImage": "codebeltnet/ubuntu-testrunner:9"
},
{
"name": "Docker-Ubuntu (net10)",
"type": "docker",
"dockerImage": "codebeltnet/ubuntu-testrunner:10"
"dockerImage": "codebeltnet/ubuntu-testrunner:8-9-10-11"
}
]
}
Loading