incubator-easyant-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jlboud...@apache.org
Subject svn commit: r1375128 - in /incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man: EasyantOption.java ListExtensionPoints.java ListProps.java ListTargets.java
Date Mon, 20 Aug 2012 17:34:37 GMT
Author: jlboudart
Date: Mon Aug 20 17:34:36 2012
New Revision: 1375128

URL: http://svn.apache.org/viewvc?rev=1375128&view=rev
Log:
Handle optional args correctly in EasyAntOptions

Modified:
    incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/EasyantOption.java
    incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListExtensionPoints.java
    incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListProps.java
    incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListTargets.java

Modified: incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/EasyantOption.java
URL: http://svn.apache.org/viewvc/incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/EasyantOption.java?rev=1375128&r1=1375127&r2=1375128&view=diff
==============================================================================
--- incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/EasyantOption.java (original)
+++ incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/EasyantOption.java Mon
Aug 20 17:34:36 2012
@@ -24,6 +24,7 @@ import org.apache.easyant.core.EasyAntCo
 import org.apache.easyant.core.EasyAntMagicNames;
 import org.apache.easyant.core.report.EasyAntReport;
 import org.apache.easyant.core.services.PluginService;
+import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.Project;
 
 /**
@@ -88,7 +89,7 @@ public abstract class EasyantOption exte
                 PluginService pluginService = (PluginService)project.getReference(EasyAntMagicNames.PLUGIN_SERVICE_INSTANCE);
                 setEareport(pluginService.generateEasyAntReport(moduleDescriptor,optionalAntModule,overrideAntModule));
             } catch (Exception e) {
-                project.log("EasyAntMan could not be initialized. Details: " + e.getMessage(),Project.MSG_ERR);
+                throw new BuildException("EasyAntMan could not be initialized. Details: "
+ e.getMessage(),e);
             }
         }
         return eareport;

Modified: incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListExtensionPoints.java
URL: http://svn.apache.org/viewvc/incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListExtensionPoints.java?rev=1375128&r1=1375127&r2=1375128&view=diff
==============================================================================
--- incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListExtensionPoints.java
(original)
+++ incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListExtensionPoints.java
Mon Aug 20 17:34:36 2012
@@ -32,7 +32,6 @@ public class ListExtensionPoints extends
     public ListExtensionPoints()
             throws IllegalArgumentException {
         super("listExtensionPoints", false, "List all phases available");
-        setOptionalArg(true);
         setStopBuild(true);
     }
 

Modified: incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListProps.java
URL: http://svn.apache.org/viewvc/incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListProps.java?rev=1375128&r1=1375127&r2=1375128&view=diff
==============================================================================
--- incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListProps.java (original)
+++ incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListProps.java Mon Aug
20 17:34:36 2012
@@ -30,7 +30,7 @@ import org.apache.easyant.core.report.Im
 public class ListProps extends EasyantOption {
 
     public ListProps() throws IllegalArgumentException {
-        super("listProps", false, "List all properties available or specified in a given
plugin as argument");
+        super("listProps", true, "List all properties available or specified in a given plugin
as argument");
         setOptionalArg(true);
         setStopBuild(true);
     }

Modified: incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListTargets.java
URL: http://svn.apache.org/viewvc/incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListTargets.java?rev=1375128&r1=1375127&r2=1375128&view=diff
==============================================================================
--- incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListTargets.java (original)
+++ incubator/easyant/core/trunk/src/main/java/org/apache/easyant/man/ListTargets.java Mon
Aug 20 17:34:36 2012
@@ -37,7 +37,7 @@ public class ListTargets extends Easyant
     
     
     public ListTargets() {
-        super("listTargets", false, "List all targets available or associated with a given
phase or plugin as argument");
+        super("listTargets", true, "List all targets available or associated with a given
phase or plugin as argument");
         setOptionalArg(true);
         setStopBuild(true);
     }



Mime
View raw message