fix: prevent copying of the node_modules directory (#17331)

As noted in #16659, everything from `App_Plugins` is copied into the web
output. This is unneeded and in the case of the `node_modules` directory
unwanted behavior, these files are sources and not output that Umbracco
needs to serve packages/extensions.

The old behavior has led to many of the "path too long" errors we've
been seeing while building extensions.
This commit is contained in:
Sebastiaan Janssen
2024-10-29 15:06:56 -07:00
committed by GitHub
parent e92a1b73f0
commit 2ff0a3fd3d

View File

@@ -32,7 +32,7 @@
<!-- Include App_Plugins content in output/publish directories -->
<Target Name="IncludeAppPluginsContent" BeforeTargets="GetCopyToOutputDirectoryItems;GetCopyToPublishDirectoryItems">
<ItemGroup>
<_AppPluginsFiles Include="App_Plugins\**" />
<_AppPluginsFiles Include="App_Plugins\**" Exclude="App_Plugins\**\node_modules\**" />
<ContentWithTargetPath Include="@(_AppPluginsFiles)" Exclude="@(ContentWithTargetPath)" TargetPath="%(Identity)" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="PreserveNewest" />
</ItemGroup>
</Target>