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

Fixing how the assemblies are referenced in NuGet #253

Merged
merged 1 commit into from
Oct 11, 2024

Conversation

aaronpowell
Copy link
Collaborator

Setting the DevelopmentDependency property will cause the nuspec to have a developmentDependency node in the metadata, which influences how the package is referenced in the consuming projects (see https://github.com/NuGet/NuGet.Client/blob/a41fd92fbbd65fb430e96b11c3277e2c96184474/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.targets#L236 for the task entrypoint).

This property would make sense if we were shipping something only for development in the nupkg (like just a source generator or analyzer) but since we're not, we're also shipping a runtime, we don't want the package considered a developmentDependency as that will influence the IncludeAssets and PrivateAssets properties of the package reference.

https://learn.microsoft.com/nuget/reference/nuspec#developmentdependency is the nuspec reference with more details here: https://github.com/NuGet/Home/wiki/DevelopmentDependency-support-for-PackageReference

Fixes #238

Setting the DevelopmentDependency property will cause the nuspec to have a developmentDependency node in the metadata, which influences how the package is referenced in the consuming projects (see https://github.com/NuGet/NuGet.Client/blob/a41fd92fbbd65fb430e96b11c3277e2c96184474/src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.targets#L236 for the task entrypoint).

This property would make sense if we were shipping something only for development in the nupkg (like just a source generator or analyzer) but since we're not, we're also shipping a runtime, we don't want the package considered a developmentDependency as that will influence the IncludeAssets and PrivateAssets properties of the package reference.

https://learn.microsoft.com/nuget/reference/nuspec#developmentdependency is the nuspec reference with more details here: https://github.com/NuGet/Home/wiki/DevelopmentDependency-support-for-PackageReference
@tonybaloney tonybaloney merged commit 6ab9cd9 into main Oct 11, 2024
40 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants