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

Dev > Main #4

Merged
merged 9 commits into from
Sep 30, 2020
Merged

Dev > Main #4

merged 9 commits into from
Sep 30, 2020

Conversation

kzu
Copy link
Member

@kzu kzu commented Sep 30, 2020

No description provided.

This might make it easier for simple project scenarios, also making it easier to understand what files are used in which tests. Currently, this is a bit indirect via the test class name and the corresponding folder under Scenarios.
This is easier to visualize than the current ordering where they end up last.
Since the PrivateAssets attribute is not a good fit in this scenario (see NuGet/Home#6041), use the common Pack metadata attribute and default it to false for MSBuild dependencies by default for build package kind.

Fixes NuGet/Home#6041
When using `<PackageReference PrivateAssets=all `, transitive dependencies were not being brough in. This required package authors to reference explicitly each and every package they wanted packaged as private assets. This was particularly annoying for build and analyzer packages, which need to package all their dependencies privately.

This commit leverages the SDK-provided `RunResolvePackageDependencies` which returns the transitive closure of all referenced packages as a list of package>parent list. We use that to add the concept of "implicit package references" that basically share the PrivateAssets=all that brought them in. The inference target then just considers both `@(PackageReference)` as well as `@(ImplicitPackageReference)` to determine the primary output dependencies to pack, but otherwise the existing logic remains unchanged.

This behavior still honors the `Pack=false` on the PackageReference, but also skips the implificly defined packages like NETStandard.Library and Microsoft.NETCore.

Fixes NuGet/Home#5103.
@kzu kzu merged commit 15006a6 into main Sep 30, 2020
@kzu kzu deleted the dev branch September 30, 2020 04:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant