title: How to redeploy remaining attachment files in Jenkins(using SVN, Tomcat)?
body: <p>I'm trying to use Jenkins to my web project. I use Spring, Maven, Subversion, and Tomcat. I succeed to build and deploy it. I could see it on localhost:8080. But there's a problem. The attachment files disappears after rebuilding(including redeployment) by Jenkins. (folder name of attachment files is 'file')</p>
  
  <p>I tried to fix it by setting 'Excluded Regions' attribute in Subversion Jenkins Plugin.</p>
  
  <p>When I set Excluded Regions '/path/file', there was no error on rebuilding but file folder became empty.</p>
  
  <p>When I set Excluded Regions '/path/file/.*', the project was built successfully. But after rebuilding, an error occurs:</p>
  
  <pre><code>ERROR: Build step failed with exception
  org.codehaus.cargo.container.ContainerException: Failed to undeploy [C:\Program Files (x86)\Jenkins\path\project.war]
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.undeploy(AbstractTomcatManagerDeployer.java:139)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:177)
      at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:77)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:147)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:117)
      at hudson.FilePath.act(FilePath.java:997)
      at hudson.FilePath.act(FilePath.java:975)
      at hudson.plugins.deploy.CargoContainerAdapter.redeploy(CargoContainerAdapter.java:114)
      at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeploy(PasswordProtectedAdapterCargo.java:93)
      at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:64)
      at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:744)
      at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
      at hudson.model.Build$BuildExecution.post2(Build.java:186)
      at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
      at hudson.model.Run.execute(Run.java:1749)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:97)
      at hudson.model.Executor.run(Executor.java:421)
  Caused by: org.codehaus.carg.container.tomcat.internal.TomcatManagerException: The Tomcat Manager responded "FAIL - Unable to delete [C:\Program Files\Apache Software Foundation\Tomcat 7.0\webapps\ROOT]. The continued presence of this file may cause problems.
  " instead of the expected "OK" message
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:715)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:501)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.undeploy(TomcatManager.java:441)
      at org.codehaus.cargo.container.tomcat.Tomcat7xRemoteDeployer.performUndeploy(Tomcat7xRemoteDeployer.java:61)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.undeploy(AbstractTomcatManagerDeployer.java:129)
      ... 18 more
  org.codehaus.cargocontainer.tomcat.internal.TomcatManagerException: The Tomcat Manager responded "FAIL - Unable to delete [C:\Program Files\Apache Software Foundation\Tomcat 7.0\webapps\ROOT]. The continued presence of this file may cause problems.
  " instead of the expected "OK" message
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:715)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.invoke(TomcatManager.java:501)
      at org.codehaus.cargo.container.tomcat.internal.TomcatManager.undeploy(TomcatManager.java:441)
      at org.codehaus.cargo.container.tomcat.Tomcat7xRemoteDeployer.performUndeploy(Tomcat7xRemoteDeployer.java:61)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.undeploy(AbstractTomcatManagerDeployer.java:129)
      at org.codehaus.cargo.container.tomcat.internal.AbstractTomcatManagerDeployer.redeploy(AbstractTomcatManagerDeployer.java:177)
      at hudson.plugins.deploy.CargoContainerAdapter.deploy(CargoContainerAdapter.java:77)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:147)
      at hudson.plugins.deploy.CargoContainerAdapter$DeployCallable.invoke(CargoContainerAdapter.java:117)
      at hudson.FilePath.act(FilePath.java:997)
      at hudson.FilePath.act(FilePath.java:975)
      at hudson.plugins.deploy.CargoContainerAdapter.redeploy(CargoContainerAdapter.java:114)
      at hudson.plugins.deploy.PasswordProtectedAdapterCargo.redeploy(PasswordProtectedAdapterCargo.java:93)
      at hudson.plugins.deploy.DeployPublisher.perform(DeployPublisher.java:64)
      at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:744)
      at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
      at hudson.model.Build$BuildExecution.post2(Build.java:186)
      at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
      at hudson.model.Run.execute(Run.java:1749)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:97)
      at hudson.model.Executor.run(Executor.java:421)
  Build step 'Deploy war/ear to a container' marked build as failure
  Finished: FAILURE
  </code></pre>
  
  <p>I wonder whether I can rebuild the project remaining the attchment folder by Jenkins.</p>