I have c# projects with packages and references in hierarchy like this
Project-A package1 package2 Project-B package3 package4 Project-C package5 package6
So project A references some packages and Project B, which references another packages and Project C, which references some third packets. I need to pack the project A into a NuGet Package so that in it has dependencies to all of the packages like this :
Project-A-Nuget package1 package2 package3 package4 package5 package6
I already tried to use .nuspec file to define dependencies like above but in that case i cant download my package because it tries to find and restore my referenced projects as packages.I tried to use just dotnet pack, but in that case it is not registering packages as dependencies
My .nuspec file looks like this
<?xml version="1.0" encoding="utf-8"?><package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"><metadata><id>ProjectA.Nuget</id><version>1.0.0</version><title>ProjectA.Nuget</title><authors>Me</authors><requireLicenseAcceptance>false</requireLicenseAcceptance><description>Description.</description><dependencies><dependency id="package1" version="[6.0.11]" /><dependency id="package2" version="[6.0.11]" /><dependency id="package3" version="[6.0.11]" /><dependency id="package4" version="[6.0.11]" /><dependency id="package5" version="[6.0.11]" /><dependency id="package6" version="[6.0.11]" /></dependencies></metadata></package>