这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@akshita31
Copy link
Contributor

@akshita31 akshita31 commented Sep 11, 2019

We needed a way to discover KernelExtensions that are part of nuget packages that do not have a "lib" folder.

This PR uses msbuild for doing so. It adds targets which does the following things:

  1. Add GeneratePathProperty to the PackageReference property group. When this is set then in the obj folder, you will be able to see a nuget.g.props file which has a property that contains the path to the nuget package, for example, PkgFluentAssertions

image

  1. The target ComputePackageRoots reads this property for all the nuget packages and stores the paths in item AddedNuGetPackage.

  2. The third target prints the values from AddedNuGetPackage target into a file *.nuget.paths
    image

Then in the package restore context we read this path and try to load extensions if any are present.

@akshita31 akshita31 force-pushed the use_msbuild_to_get_paths branch from 75bd20b to b344197 Compare September 11, 2019 03:59
@akshita31
Copy link
Contributor Author

cc @KevinRansom

@akshita31 akshita31 merged commit ab4bc5e into dotnet:master Sep 11, 2019
@akshita31 akshita31 deleted the use_msbuild_to_get_paths branch September 11, 2019 23:53
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.

2 participants