Created
September 1, 2019 03:57
-
-
Save aaronmorgan/31927380d65b8aad85ad731f40540a22 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Better option than marking files as embedded resources, particularly when working on cross platform environments with strings. | |
.csproj | |
``` | |
<ItemGroup> | |
<TestData Include="./SampleFiles/**" /> | |
</ItemGroup> | |
<Target Name="CopyCustomContent" AfterTargets="AfterBuild"> | |
<Copy SourceFiles="@(TestData)" DestinationFolder="$(OutDir)/TestData" SkipUnchangedFiles="true" /> | |
</Target> | |
``` | |
From the Microsoft documentation: https://docs.microsoft.com/en-us/visualstudio/msbuild/copy-task?view=vs-2019 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
DestinationFolder
also supports recursive copying, e.g.