Open JohanLarsson opened 5 years ago
@JohanLarsson what is your expectation for this scenario?
I'm trying to pack without <dependency id="NETStandard.Library" version="1.6.1" exclude="Build,Analyzers" />
in created package.
From what I read <PackageReference Update="NETStandard.Library" PrivateAssets="all" />
is meant for that use case.
<PackageReference Update="NETStandard.Library" PrivateAssets="all" />
was what I asked about in https://github.com/dotnet/standard/issues/601 for .NET Standard 1.x projects in order to forgo supporting VS2015-no-build-extensions and suppress the <dependency>
element.
I remember it working at one point.
This is likely caused by having moved the implict references to a CollectPackageReferences target. @dsplaisted. I think the workaround would now have to include a target, and it gets messy as Update doesn't work in targets and you have to use a harder to read Condition. :( Maybe we should have a property for this.
I'm not able to repro this with preview 8 (3.0.100-preview8-013651). The implicit PackageReferences for NETStandard.Library and Microsoft.NETCore.App are still added during evaluation.
Repro steps:
New project:
Build in VS
Inspect package: