NOTE: This is for a Visual Studio Web Site Project and NOT a Web Application
I am using web deploy to push changes from my development machine to my staging server. I would like to push any files that are different to the staging server except for one particular file (lets call it myFile.whatever)
So far I have tried editing the C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe.config
file to look like so:
<configuration>
<startup>
<supportedRuntime version="v2.0.50727" />
<supportedRuntime version="v4.0" />
</startup>
<rules> <------------ ADDED THIS NODE
<rule name="skipConfig" type="Microsoft.Web.Deployment.DeploymentSkipRuleHandler"
objectName="filePath" skipAction="Delete"
absolutePath="C:\inetpub\wwwroot\MyProject\myFile.whatever"/>
</rules>
</configuration>
But it is still overwriting the file in question on my staging server. I started by editing the msdeploy.exe.config
on my dev machine and when that didn't work I updated the msdeploy.exe.config
on my staging server as well, but again, still not working.
Am I going about this wrong? Any suggestions on preventing this file from being overwritten?