Giter Club home page Giter Club logo

Comments (7)

dasMulli avatar dasMulli commented on August 29, 2024

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>

from nuget-include-p2p-example.

dasMulli avatar dasMulli commented on August 29, 2024

let me know if this works for you

from nuget-include-p2p-example.

sonudavidson avatar sonudavidson commented on August 29, 2024

Hi,
I updated the target framework to frameworks like this way
netstandard1.4;net471
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!

from nuget-include-p2p-example.

dasMulli avatar dasMulli commented on August 29, 2024

@sonudavidson did you start with one of the code snippets in this thread? if so, which?

from nuget-include-p2p-example.

sonudavidson avatar sonudavidson commented on August 29, 2024

@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?

from nuget-include-p2p-example.

dasMulli avatar dasMulli commented on August 29, 2024

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)

from nuget-include-p2p-example.

sonudavidson avatar sonudavidson commented on August 29, 2024

Yeah, I agree. I took off the part where the values must be referenced from .csproj. Nuspec now works.

from nuget-include-p2p-example.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.