23

I use MSDeploy to publish things to different servers during CI. When I publish from Visual Studio 2010 I have a "Leave extra files on destination" option, but I can't seem to find a flag for this functionality when invoking MSDeploy from the command line.

Does anyone know how to do this??

pnuts
  • 54,806
  • 9
  • 74
  • 122
Brad Heller
  • 1,511
  • 3
  • 18
  • 28

2 Answers2

44

For msdeploy.exe you need to add -enableRule:DoNotDeleteRule to ensure content is not deleted. For more info on MSDeploy rules see http://technet.microsoft.com/en-us/library/dd568992(WS.10).aspx.

Kenny Evitt
  • 8,023
  • 5
  • 59
  • 84
Sayed Ibrahim Hashimi
  • 42,483
  • 14
  • 139
  • 172
6

If you want to choose which dirs need to be leaved, you can read http://blog.alanta.nl/2011/02/web-deploy-customizing-deployment.html

Rail
  • 680
  • 8
  • 12