zoukankan      html  css  js  c++  java
  • Microsoft.Bcl.Build.targets" cannot be imported again

     warning MSB4011: "C:workspaceCompanyFinland owdevelopSourcepackagesMicrosoft.Bcl.Build.1.0.14 oolsMicrosoft.Bcl.Build.targets" cannot be imported again. It was already imported at "C:workspaceCompanyFinland owdevelopSourceEdenredFI.WOT.MAP.APIEdenredFI.WOT.MAP.API.csproj (87,3)". This is most likely a build authoring error. This subsequent import will be ignored. 

    The build restored NuGet packages. Build the project again to include these packages in the build. For more information, see http://go.microsoft.com/fwlink/?LinkID=317568.
    ========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========

    https://devblogs.microsoft.com/dotnet/improved-package-restore/

    NuGet 2.7 makes this a lot easier:

    1. You no longer need to enable package restore explicitly – when building in VS all packages are restored automatically.
    2. Running package restore on a build machine is now super easy. You only need to check-in NuGet.exe (nothing else) and you can put it wherever you want. It can even be in a well-known location on your build server and excluded from every solution if desired. Prior to the build you simply run nuget.exe restore pathtomysolution.sln.

    Also, the NuGet team is talking to all major providers of build/CI servers (incl. TFS) so that at some point the second step can be handled automatically by the build servers. For more details, have a look at the NuGet 2.7 release notes and the new Package Restore documentation.

     

    Summary

    The new version of Microsoft.Bcl.Build will ensure that solutions containing our packages will load successfully even if packages aren’t restored yet. This affects all .NET NuGet packages that depend on it, such as Microsoft.Net.Http, Microsoft.Bcl, and Microsoft.Bcl.Async.

    Microsoft.Bcl.Build will give an actionable error message in cases the package was missing by asking you to build again.

    When coupled with NuGet 2.7 where package restore is automatic in Visual Studio and isn’t implemented through MSBuild, the experience is transparent and smooth. However, this doesn’t address build server scenarios yet so you still need run nuget.exe restore solution.sln prior to build, or check-in the .targets file if preferred.

  • 相关阅读:
    洛谷 P1226 【模板】快速幂||取余运算 题解
    洛谷 P2678 跳石头 题解
    洛谷 P2615 神奇的幻方 题解
    洛谷 P1083 借教室 题解
    洛谷 P1076 寻宝 题解
    洛谷 UVA10298 Power Strings 题解
    洛谷 P3375 【模板】KMP字符串匹配 题解
    Kafka Shell基本命令
    Mybatis与Hibernate的详细对比
    MyBatis简介
  • 原文地址:https://www.cnblogs.com/chucklu/p/15132875.html
Copyright © 2011-2022 走看看