I am trying to understand if there is any way to rely on Nuget Automatic Package Restore when referencing libraries hosted on Github. The problem is that when I add certain library as submodule, it has it's own /packages/ directory. But, when I add csproj from that library into my solution since there are no DLLs in /packages/ directory of that submodule, build fails.
Obviously, easy fix on my machine is to open up .sln file from submodule that I've referenced, do a build. Now, building from my main solution will obviously work since /packages/ folder in submodule is populated. But, this is not something I can do on build server.
Any way of solving this problem without completely messing up submodule? I obviously also don't want to change submodule .csproj because that would put it out of sync with origin. Ideally I would love if I could instruct nuget to pull packages for referenced submodule .csproj in it's own /packages/ directory.