Quantcast
Channel: Active questions tagged nuget-package - Stack Overflow
Viewing all articles
Browse latest Browse all 3171

Excluding classes from Nuget package

$
0
0

A project I'm working on is currently using 2 entities projects and it's written over .Net Standard 2.0 framework:

Contract.csproj
Contract.Internal.csproj

The first is configured to be exposed for consumers using a private Nuget server, while the second is for internal use of my solution projects.
The thing is that both has pretty much the same classes except few that are for my solution internal use only.

Is there a way to merge them to a single project and configure some classes to be exposed in the NuGet package while others are not?

I read on the ExcludeAssets/IncludeAssets tags that can be added to the csproj PackageReference, but the docs and all the examples I saw are referring dependencies and their versions and not the project classes.

Also, if you have other solution, you work with your projects some other way on this one (Or even think that I find myself with that scenario is wrong) I'll be more than happy if you share you thoughts on this.


Viewing all articles
Browse latest Browse all 3171

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>