3

It seems that when creating a nuget package with content files in .NET Core 2 the content files will be installed as linked files by default. This differs from what happens in .NET Framework which is that the files got copied into the project.

I am currently including content files using the following code in the .csproj file and then creating a nuget package using msbuild.

<Content Include="BuildExample\*.*">
  <Pack>true</Pack>
</Content>

How can I include content files which get copied into the project rather than linked into the project when the nuget package is installed?

Adam Carter
  • 145
  • 1
  • 7
  • I've found the following post which mentions that copying files to the consuming project is no longer supported: https://stackoverflow.com/questions/44709212/the-content-folder-in-my-nuget-package-isnt-adding-the-files-to-the-root-when-i#comment76428012_44710067 – Adam Carter Oct 19 '17 at 16:42
  • Since nuget 3 install.ps1 scripts are no longer available which could have provided a work around. According to answers on: https://stackoverflow.com/questions/6892025/nuget-install-ps1-does-not-get-called/ – Adam Carter Oct 20 '17 at 08:52

0 Answers0