Search code examples
c#tfsbuildreferenceblend

Newtonsoft.json.dll being copied in build server


I am trying to build a WCF C# project,which is not using the Newtonsoft.Json.dll. I checked the packages.config and *.csproj files.

When building the app in build server, Newtonsoft.Json.dll is copied to bin path Build log: Copying file from "d:\Microsoft Visual stdio 12.0\blend\newtonsoft.json.dll" to "\\bin\newtonsoft.json.dll"

Why it is getting copied ?


Solution

  • Just like the guys said above, you may be using other libraries which have dependencies on Newtonsoft. So, just check your project.

    Here is a reference for you:

    When Microsoft.TeamFoundation.Build.Client.dll(or Microsoft.TeamFoundation.Build.Common.dll) referenced by the TFS plugin is set to CopyLocal(or Private), the builder will copy all its dependencies to the plugins folder, such as

    • Microsoft.TeamFoundation.Diff.dll
    • Microsoft.TeamFoundation.VersionControl.Client.dll
    • Microsoft.TeamFoundation.WorkItemTracking.Proxy.dll
    • Newtonsoft.Json.dll version 4.5.0

    Source link : https://github.com/gitextensions/gitextensions/issues/3041