gpt4 book ai didi

c# - 如何使用 NuGet 在 Visual Studio 2012 上安装 protobuf-net?

转载 作者:太空狗 更新时间:2023-10-30 00:18:19 27 4
gpt4 key购买 nike

我想使用 NutGet 和 Visual Studio 2012 安装 protobuf-net。

但是,如果我尝试安装它,我会从 NuGet 收到以下错误消息:

'protobuf-net' already has a dependency defined for 'NETStandard.Library'.

我已尝试安装 NETStandard.Library 但出现错误:

The 'NETStandard.Library 1.6.0' package requires NuGet client version '2.12' or above, but the current NuGet version is '2.8.60318.667'.

我也尝试更新 NuGet(通过卸载然后重新安装),但它似乎在 Visual Studio 2012 中停留在 2.8 版本。

最佳答案

我没有要测试的 Visual Studio 2012,但我想知道这是否是由于 Nuget 现在使用 .Net Core 依赖项的方式所致。如果您安装旧版本的 protobuf-net,它应该可以工作.你可以看到 older version没有提到 .NETStandard 作为依赖项。为此,请从包管理器控制台键入:

Install-Package protobuf-net -Version 2.0.0.668

关于c# - 如何使用 NuGet 在 Visual Studio 2012 上安装 protobuf-net?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38654856/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com