2

Let's say I have a solution with 2 projects, MyImplementations.csproj and MyInterfaces.csproj. MyImplementations has a project reference on MyInterfaces. I would like to publish MyImplementations as a NuGet package (to a private artifact feed on Azure DevOps). I would like users of this package to be able to utilize the public portions of MyInterfaces, transitively included by MyImplementations.

What I've experienced while trying to do this is that users of MyImplementations encounter an issue where NuGet Package Manager expects there to be a second package for MyInterfaces with the same version number, and since that doesn't exist, it does not add the package.

Is it possible to do what I want, perhaps through some better configuration or alteration of my publishing tasks, or is publishing a package for MyInterfaces the only way to go?

bubbleking
  • 3,329
  • 3
  • 29
  • 49
  • Did you check this? https://stackoverflow.com/questions/44727318/pack-multiple-assemblies-with-dotnet-pack – mu88 Oct 12 '22 at 07:57
  • @mu88 - Thanks, that sent me down the right path, I think. However, what I discovered is that goading NuGet into the behaviors we are looking for seems to be too complex for our organization to spend time on. Sadly, I'm just going to have to publish the not-meant-to-be-directly-consumed packages to the feed. – bubbleking Oct 13 '22 at 21:47

0 Answers0