add support for packing framework reference assemblies #1361
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
fixes: NuGet/Home#4853
Here is how this will work:
All
<Reference>
items in the csproj will be added by default to the nuspec as aframeworkAssemblyReference
. This behavior can be overridden by specifying<Pack>false</Pack>
on the reference that you dont want to include in your nuspec.All implicit framework references will also be added by default. For a list of implicit references, see : https://github.com/dotnet/sdk/blob/release/2.0.0/src/Tasks/Microsoft.NET.Build.Tasks/build/Microsoft.NET.Sdk.BeforeCommon.targets#L84-L109
If you don't want to include implicity framework assembly references, you can set
DisableImplicitFrameworkReferences
to true. Doing this will remove all implicit framework assembly references, exceptSystem.Core
which is special and added via a different property calledAdditionalExplicitAssemblyReferences
. You can skip the addition of System.Core by specifyingAddAdditionalExplicityAssemblyReferences
to false.Tests coming soon.