In case we want to leverage this tool other places like VS then we need to make library which create mapping directly from source.
Currently this tool requires solution to be restored before generating packagesourcemapping section, it created in this way to cover all possible scenarios, for example if there is any powershell scripts doing custom restore then it's very hard to deduce it directly, instead working on end result is much easier.
For packages.config projects it's quite straightforward, but for packagesreferences need to evaluate actual project/solution to figure out resolved packages used in it.
For my ref: NuGet/Home#11656 (comment)
In case we want to leverage this tool other places like VS then we need to make library which create mapping directly from source.
Currently this tool requires solution to be restored before generating packagesourcemapping section, it created in this way to cover all possible scenarios, for example if there is any powershell scripts doing custom restore then it's very hard to deduce it directly, instead working on end result is much easier.
For packages.config projects it's quite straightforward, but for packagesreferences need to evaluate actual project/solution to figure out resolved packages used in it.
For my ref: NuGet/Home#11656 (comment)