I am currently attempting to use Visual Studio 2010 \'Publish\' and MSDeploy functionality to handle my web deployment needs but have run into a roadblock with regards to cu
I found a workaround for the problem by using the ExcludeFilesFromDeployment element within the project file. I got the idea from Web Deployment: Excluding Files and Folders
So if you need to package project files as they exist in your project directory after a successful build and associated post build steps then do the following.
PropertyGroup element associated to the configuration setting e.g. "Release"Within the PropertyGroup element add in the following elements and exclude files and folders you don't want in the package
*.cs;**\.svn\**\*.*;Web.*.config;*.csproj*
.svn;Controllers;BootstrapperTasks;Properties
Save and reload your project
This solves my problem for the time being but if there is a better solution then please let me know, as this is not ideal due to the hackery involved, but then again perhaps this is an uncommon deployment scenario?