VS 2017 class library project includes App.Config when "Do not copy" selected for "Copy to Output Directory"

时间:2017-06-04 23:47:47

标签: visual-studio-2017

Noticed that Visual Studio 2017 includes {ClassProjectName}.DLL.Config file if the class library has an App.Config and "Copy to Output Directory" is set to "Do not copy". In VS2015 this setting would not copy the .config file

How to move to VS2015 way of publish

1 个答案:

答案 0 :(得分:0)

将此添加到现有元素内的发布配置文件("我的Project \ PublishProfiles"中的.pubxml文件):

<ExcludeFilesFromDeployment>bin\*.dll.config</ExcludeFilesFromDeployment>