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

How to Exclude Content directory in Nuget

$
0
0

I am trying to build nuget with my csproj and MSBuild.Nuget package gets created successfully. But I see content and contentFiles folder where it has my 20 .proto files.And when someone downloads my nuget, they also get my proto files. But I don't want to give those files. How Can I avoid having .proto files.

I don't have .nuspec file.

My csproj looks like this :

<PropertyGroup><TargetFramework>netstandard2.0</TargetFramework><ProduceReferenceAssemblyInOutDir>true</ProduceReferenceAssemblyInOutDir><PackageId>BlahBlah</PackageId><Title>BlahBlah</Title><Version>1.0.0</Version><Authors>Test</Authors><Company>Test</Company><PackageTags>Test nuget</PackageTags><DebugType>portable</DebugType><AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>        <PackageOutputPath>Blah</PackageOutputPath></PropertyGroup><Target Name="Test1" AfterTargets="Pack" Condition="$(PackOnBuild) == 'true'"><ItemGroup><PackageFile Include="$(TestVersion).nupkg" /></ItemGroup><Copy SourceFiles="@(src)" DestinationFolder="$(dst)" /></Target>

Viewing all articles
Browse latest Browse all 3067

Trending Articles



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