简体   繁体   English

在VS2017中将依赖程序集包含在NuGet包中

[英]Including a dependent assembly into a NuGet package in VS2017

I have a solution with 2 projects (NET Core). 我有一个有2个项目(NET Core)的解决方案。 The first project (library) contains the main assembly, the other project (library) contains an assembly with resources, interfaces and other stuff. 第一个项目(库)包含主程序集,另一个项目(库)包含一个包含资源,接口和其他东西的程序集。 The main project references the second project. 主项目引用了第二个项目。

I am using Visual Studio 2017. When I create a NuGet package from the main project, the satellite assembly is not included in the package's lib folder. 我正在使用Visual Studio 2017.当我从主项目创建NuGet包时,附件组件不包含在包的lib文件夹中。 How can this be achieved? 怎么能实现这一目标?

Note: I don't want to reference the satellite assembly as NuGet package, I want this assembly to be part of the main package. 注意:我不想将附属程序集引用为NuGet包,我希望这个程序集成为主程序包的一部分。

尝试:nuget pack mainproject.csproj -IncludeReferencedProjects

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM