tjackadams
tjackadams

Reputation: 865

TFS get latest version does not restore references

I have a project that i have been developing on my machine that is checked into source control (tfs).

I would now like another developer to work on the project with me. They have connected to the tfs server and configured the local workspace. However when they say "get latest version", it downloads the project as expected, NUGET restores the packages as expected. But pretty much all of the references to the packages show up as missing and thus the project will not compile.

Here is a screenshot of the issue.

enter image description here

Here is my NuGet.Config

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <solution>
    <add key="disableSourceControlIntegration" value="true" />
  </solution>
</configuration>

and here is my .tfignore file

\packages
!\packages\repositories.config

I'm not quite sure what the issue could be. We are both using Visual Studio 2015 Enterprise Update 2 with TFS Express 2015 Update 2. Any help is appreciated.

Upvotes: 0

Views: 1302

Answers (2)

tjackadams
tjackadams

Reputation: 865

The problem in the end was that although i had created the .tfignore file, i had already checked in the packages folder into source control so this was having no effect.

Deleting the packages folder from the code section in the tfs webpage resolved this issue and packages now restore as expected on new target machines.

Thanks for all the help!

Upvotes: 1

Cece Dong - MSFT
Cece Dong - MSFT

Reputation: 31075

  1. Check whether the Nuget Package Manager has updated to the latest version
  2. Check the Nuget Package Manager setting in VS, make sure the items below are selected:

Allow NuGet to download missing packages

Automatically check for missing packages during build in Visual Studio

enter image description here

Upvotes: 3

Related Questions