2

I found a similar question without answer. Do things have changed since then? Does anybody knows how to tell VS do not erase files under a specific folder when using the great Publish Web Deploy feature?

Community
  • 1
  • 1
kiewic
  • 15,852
  • 13
  • 78
  • 101

1 Answers1

0

I typically do not include these types of locations as part of the project. I typically make an app setting that references a location that I make as a virtual directory in IIS; something like ~/Data or ~/CustomerRepo. The app doesn't care that the folder isn't in my project so long as when it runs, that location exists in IIS either physically or virtually (mostly virtually).

This way, when you publish and IIS is pointing to a virtual directory on some other part of the drive/network/whereever.. it's not overwritten.

Hardrada
  • 728
  • 8
  • 19