dotnet / NuGet.BuildTasks

The build tasks used to pick up package content from project.lock.json.
MIT License
46 stars 61 forks source link

Support reading package folder locations out of the lock file #16

Closed jasonmalinowski closed 8 years ago

jasonmalinowski commented 8 years ago

The task previously was constructing the path to the user's packages location itself, which had various issues. It meant that if the restore was done with a different path, we don't know that. It also meant we didn't handle the paths specified in nuget.config. Now, if the paths are present in the lock file, we'll use that. Otherwise, we'll construct our old path as before. Any explicitly given path to the task is still used no matter what.

Review: @NuGet/build-tasks-team, @emgarten, @yishaigalatzer, @rrelyea

jasonmalinowski commented 8 years ago

@yishaigalatzer, @emgarten, I have tried to update the logic to look for the hash file instead of the folder, but that's breaking some older tests. Was that only written out in newer versions of NuGet? Looking at some older lock files, I see that it wasn't mentioned in the libraries path like it is today.

jasonmalinowski commented 8 years ago

And updated to look for hash files with an updated hack.

emgarten commented 8 years ago

LGTM :rocket: :shipit:

ericstj commented 8 years ago

LGTM