.net core copy file in folder to root

Code Example - .net core copy file in folder to root

                
                        <ContentWithTargetPath Include="lib\some_file.dat">
  <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
  <TargetPath>some_file.dat</TargetPath>
</ContentWithTargetPath>