nuget - 使用二进制内容文件创建 Nuget 包 - 这可能吗?

标签 nuget nuget-package nuget-package-restore nuget-spec

我尝试在 contentFiles 文件夹中创建一个包含二进制文件的 nuget 包。

不幸的是,当我尝试恢复时,我收到一条错误消息,指出该文件是二进制文件而不是 ascii 文本。

有没有什么方法可以将二进制文件添加到正确还原的 NugetPackage 的 ContentFiles 文件夹中?

最佳答案

应该是可以的。您是否确保将构建操作强制为无(默认为编译)?

<contentFiles>
    <files include="**/*.*" buildAction="None" copyToOutput="true" />
</contentFiles>

关于nuget - 使用二进制内容文件创建 Nuget 包 - 这可能吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48887182/

相关文章:

.net - Webmatrix 3.0 nuGet 关于 Net.Http 的投诉

wpf - 如何为 VSE 2013 桌面安装 MVVMLight 片段

nuget - 安装nuget时需要打开一个readme.md文件

.net - 如何从 Windows 上的 devcontainer 中的私有(private) NugetFeed 恢复 Nuget 包?

nuget - 一个 NuGet 包(SQLite Core)导致 TFS 构建失败

c# - 使用 asp.net core 2.2 恢复 nuget 包时出现问题

typescript - 如何在 VS2017 中使用通过 NuGet 安装的 Typescript 定义(类型)文件?

c# - 如何设置 nuget 引用的动态路径?

visual-studio - 无法加载文件或程序集 'Microsoft.VisualStudio.ConnectedServices,如何安装?

asp.net-mvc - 为什么软件包更新后出现 "Method not found: ' Void System.Web.Http.HttpResponseException..ctor”?