tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rmannibu...@apache.org
Subject svn commit: r1443778 - in /tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin: AbstractTomEEMojo.java UpdatableTomEEMojo.java
Date Thu, 07 Feb 2013 23:21:57 GMT
Author: rmannibucau
Date: Thu Feb  7 23:21:57 2013
New Revision: 1443778

URL: http://svn.apache.org/r1443778
Log:
using context by default for updates in tomee mvn plugin

Modified:
    tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java
    tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/UpdatableTomEEMojo.java

Modified: tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java?rev=1443778&r1=1443777&r2=1443778&view=diff
==============================================================================
--- tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java
(original)
+++ tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java
Thu Feb  7 23:21:57 2013
@@ -491,7 +491,7 @@ public abstract class AbstractTomEEMojo 
         deployedFile = out;
     }
 
-    private String destinationName() {
+    protected String destinationName() {
         if (context != null) {
             if (warFile.getName().endsWith(".war")) {
                 return context + ".war";

Modified: tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/UpdatableTomEEMojo.java
URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/UpdatableTomEEMojo.java?rev=1443778&r1=1443777&r2=1443778&view=diff
==============================================================================
--- tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/UpdatableTomEEMojo.java
(original)
+++ tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/UpdatableTomEEMojo.java
Thu Feb  7 23:21:57 2013
@@ -57,9 +57,6 @@ public abstract class UpdatableTomEEMojo
     @Parameter(property = "tomee-plugin.baseDir", defaultValue = "${project.basedir}", readonly
= true)
     private File baseDir;
 
-    @Parameter(property = "tomee-plugin.finalName", defaultValue = "${project.build.finalName}")
-    private String finalName;
-
     @Parameter(property = "tomee-plugin.reload-on-update", defaultValue = "false")
     private boolean reloadOnUpdate;
 
@@ -85,6 +82,7 @@ public abstract class UpdatableTomEEMojo
     }
 
     private void initSynchronization(final Synchronization synchronization) {
+        final String destination = destinationName().replaceAll("\\.[jew]ar", "");
         if (synchronization.getBinariesDir() == null) {
             synchronization.setBinariesDir(new File(buildDir, "classes"));
         }
@@ -92,10 +90,10 @@ public abstract class UpdatableTomEEMojo
             synchronization.setResourcesDir(new File(baseDir, "src/main/webapp"));
         }
         if (synchronization.getTargetResourcesDir() == null) {
-            synchronization.setTargetResourcesDir(new File(catalinaBase, webappDir + "/"
+ finalName));
+            synchronization.setTargetResourcesDir(new File(catalinaBase, webappDir + "/"
+ destination));
         }
         if (synchronization.getTargetBinariesDir() == null) {
-            synchronization.setTargetBinariesDir(new File(catalinaBase, webappDir + "/" +
finalName + "/WEB-INF/classes"));
+            synchronization.setTargetBinariesDir(new File(catalinaBase, webappDir + "/" +
destination + "/WEB-INF/classes"));
         }
         if (synchronization.getUpdateInterval() <= 0) {
             synchronization.setUpdateInterval(5); // sec



Mime
View raw message