I am trying to find out how to exclude files when using the publishing feature in VS (2017 to be exact).
The documentation is not great, but it seems adding
<ItemGroup> <Content Update="file name"> <CopyToPublishDirectory>Never</CopyToPublishDirectory> </Content> </ItemGroup>
("file name" was set to web.config, but also folders and other files were tested)
to the profile.pubxml under
<project> should do the trick, but it doesn't :(
I have tried changing "Never" to "false" as VS intelisense seems to suggest that.
I have also tried
<ItemGroup> <Content Update="file name" CopyToPublishDirectory="Never" /> </ItemGroup>
As that was suggested in different posts when Googling.
Does anyone have the solution for this?