.Net restore unable to resolve .NET Framework libraries (4.5.2, 4.5.6)

(682 Views)


While creating a web API project, the version of Nuget on the Hosted Build Agents does not work with this mix of core and framework. In order to fix this, follow these steps:

  • Add a variable called NugetDownloadUrl with a value https://dist.nuget.org/win-x86-commandline/v3.5.0-rc1/NuGet.exe
  • Add a PowerShell task to download the Release Candidate nuget. Use the following command: -Invoke-WebRequest -OutFile

    .Net restore unable to resolve .NET Framework libraries(4.5.2, 4.5.6) Powershell command

  • Add a standard Nuget restore task pointed explicitly at NuGet.exe file that was downloaded: $(Build.ArtifactStagingDirectory)\Nuget.exe

    NugetRestore .Net restore unable to resolve .NET Framework libraries(4.5.2, 4.5.6)

    After this, compile your project, it will compile your dotnet framework projects and restore the dotnet core packages.

Solution Worked 4 UpvotesUpvote

        

Solution Didn't Worked 1 DownvotesDownvote



Comments



Search

Play 2048 Game Online

Search Tags