I have a solution with multiple projects in it checked in to TFS (Visual Studio Team Services). I only want one of those projects (and therefore its dependencies) to build and deploy to an Azure Web Site I have created. My solution and its projects follow the NuGet 2.7+ Automatic Package Restore method according to this guide. Everything works as expected in my local Visual Studio 2013 environment.
I created a very basic deployment build in Team Services using this guide, but the build fails with this error regarding NuGet:
****************************************************************************** Running tasks ****************************************************************************** ****************************************************************************** Starting task: Build solution $/Path/To/My/Project.csproj ****************************************************************************** Executing the powershell script: C:\LR\MMS\Services\Mms\TaskAgentProvisioner\Tools\agents\default\tasks\VSBuild\1.0.16\VSBuild.ps1 C:\LR\MMS\Services\Mms\TaskAgentProvisioner\Tools\agents\default\agent\worker\tools\NuGet.exe restore "C:\a\1\s\Path\To\My\Project.csproj" -NonInteractive MSBuild auto-detection: using msbuild version '14.0' from 'C:\Program Files (x86)\MSBuild\14.0\bin'. Cannot determine the packages folder to restore NuGet packages. Please specify either -PackagesDirectory or -SolutionDirectory. Unexpected exit code 1 returned from tool NuGet.exe
My question is: how exactly do I specify either -PackagesDirectory or -SolutionDirectory
? I wasn't able to find any documentation regarding this.
Or, perhaps I am going about this in the wrong way altogether?