Description
We want to enable built-in NuGet package validation to automatically detect public API changes compared to the latest released version of the package.
The goal is to ensure that breaking or incompatible public API changes are detected during build or pack, before publishing a new version to NuGet.
Proposed changes
Add the following properties to the project file:
<EnablePackageValidation>true</EnablePackageValidation>
<PackageValidationBaselineVersion>x.x.x</PackageValidationBaselineVersion>
Expected outcome
- Public API changes are validated against the specified baseline package version.
- Breaking changes cause the build or pack to fail.
- Reduced risk of unintentionally shipping breaking changes.
Notes
This uses the .NET SDK built-in package validation (ApiCompat) and does not require any additional external tools.
Description
We want to enable built-in NuGet package validation to automatically detect public API changes compared to the latest released version of the package.
The goal is to ensure that breaking or incompatible public API changes are detected during build or pack, before publishing a new version to NuGet.
Proposed changes
Add the following properties to the project file:
Expected outcome
Notes
This uses the .NET SDK built-in package validation (ApiCompat) and does not require any additional external tools.