Issue with VS2015 using MS Version-Control

If I make a branch, for some reason, all of my references get broken despite the various .dlls still being present in the /packages directory.

The packages.config file of the project in the solution still has each of the packages listed. The reference paths in the project.csproj file all point to valid files yet they don't seem to load.

I've tried:

  • Deleting the packages directory, which then triggers nuget to re-create the directory and re-download the packages but severely breaks the references (turns the warnings into errors).

  • Uninstalling and re-installing each individual package. This does not work either and a reinstall seems to trigger the removal and re-installation of all packages which, again, severely breaks the project.

  • Nuget package recovery. Does nothing.

The only way that I've found to be the easiest is to, after creating the branch is to copy the entire packages directory from the branched project and copy it into the directory of the new branch. There are typically one or two package errors after that to fix but it's a far cry from 80+ package warnings/errors.

This is very frustrating as I use this (probably like most other people) to test new features and ways of doing stuff while still maintaining a properly working version.

by Quesa-dilla via /r/csharp

Leave a Reply