Debug and release nuget packages local repository

后端 未结 1 700
天命终不由人
天命终不由人 2021-02-05 21:25

We are experimenting with nuget for our visual studio projects. However, we only (or at least mainly) use nuget for our own external references, and we store them in a local rep

1条回答
  •  不知归路
    2021-02-05 22:01

    A NuGet package will normally hold just a single set of assemblies for a particular target framework. It is not really designed to ship a debug and release version since you are publishing the NuGet package to be consumed by other users. Normally you do not publish a debug and a separate release version of your application to end users.

    You may be able to workaround this by using a custom MSBuild .targets file in the NuGet package that has its own references and configuration information. You can use this .targets file as an extension to your project. It will be imported so you can define the references as you need based on the configurations defined in your project. It is not ideal but it should work.

    0 讨论(0)
提交回复
热议问题