Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to exclude web.config when publishing with Visual Web Developer Express?

Tags:

vwdexpress

When using the project publish feature in Visual Web Developer Express Edition 2008. How can you exclude publishing the web.config so that it doesn't overwrite the server web.config?

I've tried setting the following in the web.config, which works for any other files ending .config but not the web.config for some reason.

<buildProviders>
  <remove extension=".config" />
  <add extension=".config" type="System.Web.Compilation.IgnoreFileBuildProvider"/>
</buildProviders>
like image 788
David Glenn Avatar asked Aug 17 '09 16:08

David Glenn


1 Answers

I can't believe this is so simple but never got answered. I found the answer in this question

Simply select the web.config properties and change 'Build Action' to 'None' and 'Copy To Output Directory' to 'Do Not copy'

like image 160
David Glenn Avatar answered Nov 01 '22 17:11

David Glenn