nwheels-io / NuLink

The missing LINK feature of NuGet: develop & test packages as if they were part of the main project
MIT License
53 stars 15 forks source link

Get package info from project.assets.json if SDK-Style project #26

Open MichelJansson opened 4 years ago

MichelJansson commented 4 years ago

Thanks for an essential tool!

Currently there is some issues with linking packages that does not have exact version, ie. Version="1.0.0-*" since that version string is straight "copied" as a folder.

One solution to this could be to read obj/project.assets.json that is generated by dotnet restore instead of the .csproj to get the currently restored version. This file also gives the benefit of that it also holds the path to the packages folder, removing the need to read the *.nuget.g.props

I'm willing to submit a PR for this it you think it sound like a good idea.

felix-b commented 4 years ago

Hi @MichelJansson, thanks for giving this tool a try! Yes, the idea sounds good, and a PR would be welcome.