Open UncleFirefox opened 6 years ago
I think I can revise it to something much more simple for the 2.0.0 tooling:
<Project>
<PropertyGroup>
<TargetFrameworks>netstandard2.0;netstandard1.6</TargetFrameworks>
<TargetsForTfmSpecificBuildOutput>$(TargetsForTfmSpecificBuildOutput);IncludeP2PAssets</TargetsForTfmSpecificBuildOutput>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\testprivatelib\testprivatelib.csproj" PrivateAssets="All" />
</ItemGroup>
<Target Name="IncludeP2PAssets">
<ItemGroup>
<BuildOutputInPackage Include="$(OutputPath)\testprivatelib.dll" />
</ItemGroup>
</Target>
</Project>
let me know if this works for you
Hi, I updated the target framework to frameworks like this way
Added the same line in all the 3 projects,
While building the solution, I get the following error,
error NU5019: File not found: 'bin\Debug\LibA.dll'
Looks like a similar change, Couldn't figure out the reason. Looking for some help.
Thanks!
@sonudavidson did you start with one of the code snippets in this thread? if so, which?
@dasMulli Thanks for the reply. It was my mistake. I was able to solve it. Although I have another issue, Sometimes, the values from .csproj file are not referenced properly in NuSpec. Do you also see this issue?
There are two ways of packing a nuspec. packing the nuspec and referencing the nuspec from a csproj for dotnet pack
. First one doesn't really work with .net core projects, second one also requires you to construct the set of variables for the nuspec inside the csproj.
I usually recommend not using either of them and maxing out what can be done with csproj alone. There are only a few things that cannot be done in csproj (e.g. reference groups for packages.config base projects)
Yeah, I agree. I took off the part where the values must be referenced from .csproj. Nuspec now works.
Hi, I'm trying hack 2 from your answer on stack overflow using:
Project is very simple but it doesn't copy Adaptive.Agrona.dll into the pkg, any ideas on why it's failing?