0

I have TFS service on premise. I am trying to setup build and stuck on nuget restore step. I have pass target solution to settings:

Path to solution or packages.config: $/MyProject/MySolution.sln 

On log, nuget fails due to invalid directory

NuGet.exe restore -NonInteractive D:\TFS\agent01\_work\63\s -ConfigFile \\SomePath\Nuget.config -NoCache -Verbosity Detailed 

As you can see, invalid target is passed to nuget. It should be

D:\TFS\agent01\_work\63\s\$\MyProject\MySolution.sln 

But is

D:\TFS\agent01\_work\63\s 

In other projects works as expected. What could be wrong?

2 Answers 2

1

Do you have it declared as a build step? It looks like you somewhere put a remote path where it can't be resolved on the agent. I have a very similar setup running and it works with the NuGet-Installer build step:

enter image description here

Sign up to request clarification or add additional context in comments.

Comments

0

It turned out that, the problem was Get Source step. In Server path variable I had path to solution itself instead of( sln file) of folder to solution.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.