Search code examples
visual-studio-2012msdeploy

Publishing a Web Application from VS2012 is wiping out user content


I'm attempting to use Web Deploy to Publish a Web Application. I want Visual Studio to delete any files that no longer exist, so I've checked the "Remove additional files at destination" setting in my Publishing profile. However, I want VS to ignore the /Content/uploads folder, as it contains contents that my users have uploaded. Naturally, the contents are different in my development site than they are in the live site. Unfortunately, I have been unable to discover a way to make Visual Studio ignore this folder when publishing (it wants to delete all of the content, since it doesn't exist in the project). Does anyone know of a way to exclude specific folders on the target site from being examined by Web Deploy?


Solution

  • I was unable to find a suitable solution for this issue, so I've created my own: https://pubsync.codeplex.com/

    PubSync enables quick and reliable file syncing for publishing Visual Studio projects.