smor        2002/07/08 09:47:25

  Modified:    src/java/org/apache/maven/jelly/tags/project GoalsToXML.java
               src/plugins/activity plugin.jelly
               src/plugins/ant plugin.jelly
               src/plugins/changelog plugin.jelly
               src/plugins/checkstyle plugin.jelly
               src/plugins/clover plugin.jelly
               src/plugins/java plugin.jelly
               src/plugins/javadoc plugin.jelly
               src/plugins/jdepend plugin.jelly
               src/plugins/jxr plugin.jelly
               src/plugins/test plugin.jelly
  Log:
  Added descriptions so that goals appear sorted and documented when
  you type "maven -g".
  
  Added some aliases for most common goals, so that one can do :
  "maven checkstyle", "maven changelog", "maven test", etc...
  
  We should also adopt the <plugin>:<goal> name convention, but
  before that me must deprecate them as they can still be used.
  
  /!\ Modified clover goals, so that it respects the plugin:name
  scheme, as almost every goal in this plugin has a different name
  convention !  /!\
  
  Eventually, we might deprecate some goals, as they have almost
  no use with "common names" aliases, rather than "site:generate",
  or something like that.
  
  Revision  Changes    Path
  1.2       +7 -7      
jakarta-turbine-maven/src/java/org/apache/maven/jelly/tags/project/GoalsToXML.java
  
  Index: GoalsToXML.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-turbine-maven/src/java/org/apache/maven/jelly/tags/project/GoalsToXML.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- GoalsToXML.java   8 Jul 2002 06:06:03 -0000       1.1
  +++ GoalsToXML.java   8 Jul 2002 16:47:23 -0000       1.2
  @@ -142,15 +142,15 @@
   
               int id = 0;
   
  -            ps.print("<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>");
  -            ps.print("<project default=\"" + werkzProject.getDefaultGoalName() + 
"\">");
  +            ps.print("<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n");
  +            ps.print("<project default=\"" + werkzProject.getDefaultGoalName() + 
"\">\n");
   
               while (goalIter.hasNext())
               {
                   eachGoal = (Goal) goalIter.next();
                   
  -                ps.print("  <goal id=\"" + id + "\" name=\"" + eachGoal.getName() + 
"\"");
  -                ps.print("        description=\"" + eachGoal.getDescription() + 
"\">");
  +                ps.print("  <goal id=\"" + id + "\" name=\"" + eachGoal.getName() + 
"\"\n");
  +                ps.print("        description=\"" + eachGoal.getDescription() + 
"\">\n");
   
                   Collection prerequisites = eachGoal.getPrerequisites();
   
  @@ -163,14 +163,14 @@
                   while (prereqIterator.hasNext())
                   {
                       prereq = (Goal) prereqIterator.next();
  -                    ps.print("    <prerequisite name=\"" + prereq.getName() + 
"\"/>");
  +                    ps.print("    <prerequisite name=\"" + prereq.getName() + 
"\"/>\n");
                   }
   
  -                ps.print("  </goal>");
  +                ps.print("  </goal>\n");
                   id++;
   
               }
  -            ps.print("</project>");
  +            ps.print("</project>\n");
           }
           finally 
           {
  
  
  
  1.5       +6 -1      jakarta-turbine-maven/src/plugins/activity/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/activity/plugin.jelly,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- plugin.jelly      5 Jul 2002 21:48:19 -0000       1.4
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.5
  @@ -18,7 +18,12 @@
       <classpath refid="maven-classpath"/>
     </taskdef>
   
  -  <goal name="activity:generate">
  +  <goal name="activity"
  +        description="Generate developper activity and file activity reports"
  +        prereqs="activity:generate"/>
  +
  +  <goal name="activity:generate"
  +        description="Generate developper activity and file activity reports">
   
       <mkdir dir="${maven.build.dir}/generated-xdocs"/>
   
  
  
  
  1.10      +6 -1      jakarta-turbine-maven/src/plugins/ant/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/ant/plugin.jelly,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- plugin.jelly      8 Jul 2002 13:36:31 -0000       1.9
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.10
  @@ -12,8 +12,13 @@
     <!-- people who want to build from sources but don't want to use Maven. -->
     <!-- ================================================================== -->
   
  +  <jj:goal name="ant"
  +           description="Generate an Ant build file"
  +           prereqs="ant:generate-build"/>
  +
     <jj:goal
  -    name="ant:generate-build">
  +    name="ant:generate-build"
  +    description="Generate an Ant build file">
   
       <j:file name="build.xml">
       <j:whitespace>
  
  
  
  1.3       +6 -1      jakarta-turbine-maven/src/plugins/changelog/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/changelog/plugin.jelly,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- plugin.jelly      4 Jul 2002 04:41:32 -0000       1.2
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.3
  @@ -12,7 +12,12 @@
       <classpath refid="maven-classpath"/>
     </taskdef>
   
  -  <goal name="changelog:generate">
  +  <goal name="changelog"
  +        description="Generate a changelog report"
  +        prereqs="changelog:generate"/>
  +
  +  <goal name="changelog:generate"
  +        description="Generate a changelog report">
   
       <mkdir dir="${maven.build.dir}/generated-xdocs"/>
   
  
  
  
  1.6       +6 -1      jakarta-turbine-maven/src/plugins/checkstyle/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/checkstyle/plugin.jelly,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- plugin.jelly      5 Jul 2002 21:48:19 -0000       1.5
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.6
  @@ -18,8 +18,13 @@
       <classpath refid="maven-classpath"/>
     </taskdef>
   
  +  <goal name="checkstyle"
  +        description="Generate code convention conformance reports"
  +        prereqs="checkstyle:generate-report"/>
  +
     <goal 
  -    name="checkstyle:generate-report">
  +    name="checkstyle:generate-report"
  +    description="Generate code convention conformance reports">
   
       <j:if test="${sourcesPresent == 'true'}">
       
  
  
  
  1.5       +15 -8     jakarta-turbine-maven/src/plugins/clover/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/clover/plugin.jelly,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- plugin.jelly      6 Jul 2002 04:49:10 -0000       1.4
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.5
  @@ -7,7 +7,8 @@
     <!-- =================================================================== -->
   
     <goal
  -    name="clover-prepare">
  +    name="clover:prepare"
  +    description="Create the needed directory structure">
   
       <!-- The clover.initstring must be defined and must point to the database
            file -->
  @@ -20,7 +21,7 @@
       <mkdir dir="${maven.clover.database.dir}"/>
       
       <attainGoal name="java:compile"/>
  -    <attainGoal name="java:compile-test"/>
  +    <attainGoal name="test:compile"/>
       
     </goal>
   
  @@ -28,8 +29,9 @@
     <!-- Compile with Clover to instrument source code                       -->
     <!-- =================================================================== -->
     <goal
  -    name="clover-compile"
  -    prereqs="clover-prepare">
  +    name="clover:compile"
  +    description="Compile with Clover to instrument source code"
  +    prereqs="clover:prepare">
   
       <property name="build.compiler"
           value="org.apache.tools.ant.taskdefs.CloverCompilerAdapter"/>
  @@ -63,8 +65,9 @@
     <!-- =================================================================== -->
   
     <goal
  -    name="clover-test"
  -    prereqs="clover-compile">
  +    name="clover:test"
  +    description="Run unit tests with Clover"
  +    prereqs="clover:compile">
   
       <j:if test="${flags.sourceTestDirectory}">
       
  @@ -93,8 +96,12 @@
     <!-- C L O V E R  R E P O R T S                                          -->
     <!-- =================================================================== -->
   
  +  <goal name="clover"
  +        description="Generate HTML test coverage reports with Clover"
  +        prereqs="clover:test, clove:html-report"/>
  +
     <goal
  -    name="clover-report-html"
  +    name="clover:html-report"
       description="Generate HTML test coverage reports with Clover">
   
       <mkdir dir="${maven.docs.dest}/clover"/>
  @@ -114,7 +121,7 @@
     </goal>
   
     <goal
  -    name="clover-report-swing"
  +    name="clover:swing-report"
       description="Generate Swing test coverage reports with Clover">
   
       <mkdir dir="${maven.docs.dest}/clover"/>
  
  
  
  1.4       +13 -4     jakarta-turbine-maven/src/plugins/java/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/java/plugin.jelly,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- plugin.jelly      8 Jul 2002 15:16:17 -0000       1.3
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.4
  @@ -63,7 +63,8 @@
     <!--     prepare-filesystem                                             -->
     <!-- ================================================================== -->
   
  -  <goal name="java:prepare-filesystem">
  +  <goal name="java:prepare-filesystem"
  +        description="Create the directory structure needed to compile">
       <mkdir dir="${maven.build.dest}"/>
     </goal>
   
  @@ -72,6 +73,7 @@
     <!-- ================================================================== -->
   
     <goal name="java:compile"
  +        description="Compile the project"
           prereqs="java:prepare-filesystem">
   
       <property name="cp" refid="maven.dependency.classpath"/>
  @@ -96,7 +98,8 @@
     <!--     jar resources                                                  --> 
     <!-- ================================================================== -->
   
  -  <goal name="java:jar-resources">
  +  <goal name="java:jar-resources"
  +        description="Copy any resources that must be present in the deployed JAR 
file">
   
       <j:if test="${maven.has.jar.resource.patterns}">
   
  @@ -149,7 +152,8 @@
     <!-- ================================================================== -->
   
     <goal
  -    name="java:snapshot">
  +    name="java:snapshot"
  +    description="Create a snapshot jar, ie 'id-YYYYMMDD.buildnumber.jar'">
   
       <maven:snapshot project="${pom}"/>    
       <j:set var="maven.final.name" value="${snapshotSignature}"/>
  @@ -163,8 +167,13 @@
     <!-- S I T E  G E N E R A T I O N                                       -->
     <!-- ================================================================== -->
   
  +  <goal name="site"
  +        description="Generate the web site"
  +        prereqs="site:generate"/>
  +
     <goal 
  -    name="site:generate">
  +    name="site:generate"
  +    description="Generate the web site">
       
         <attainGoal name="jdepend:generate-report"/>
         <attainGoal name="checkstyle:generate-report"/>
  
  
  
  1.4       +6 -1      jakarta-turbine-maven/src/plugins/javadoc/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/javadoc/plugin.jelly,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- plugin.jelly      5 Jul 2002 01:35:16 -0000       1.3
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.4
  @@ -6,8 +6,13 @@
     <!-- J A V A D O C S                                                    -->
     <!-- ================================================================== -->
   
  +  <goal name="javadoc"
  +        description="Generate API documentation"
  +        prereqs="javadoc:generate"/>
  +
     <goal
  -    name="javadoc:generate">
  +    name="javadoc:generate"
  +    description="Generate API documentation">
       
       <j:if test="${sourcesPresent == 'true'}">
   
  
  
  
  1.7       +6 -0      jakarta-turbine-maven/src/plugins/jdepend/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/jdepend/plugin.jelly,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- plugin.jelly      6 Jul 2002 04:49:10 -0000       1.6
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.7
  @@ -12,8 +12,14 @@
       <classpath refid="maven-classpath"/>
     </taskdef>
   
  +  <goal name="jdepend"
  +        description="Generate a dependency report with JDepend"
  +        prereqs="jdepend:generate-report"/>
  +
  +  <!-- Should we deprecate it to use only "jdepend" ? -->
     <goal 
       name="jdepend:generate-report"
  +    description="Generate a dependency report with JDepend"
       prereqs="java:compile">
   
       <j:if test="${sourcesPresent == 'true'}">
  
  
  
  1.7       +7 -1      jakarta-turbine-maven/src/plugins/jxr/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/jxr/plugin.jelly,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- plugin.jelly      6 Jul 2002 12:56:34 -0000       1.6
  +++ plugin.jelly      8 Jul 2002 16:47:24 -0000       1.7
  @@ -12,8 +12,14 @@
       <classpath refid="maven-classpath"/>
     </taskdef>
   
  +  <goal name="jxr"
  +        description="Generate HTML cross reference sources"
  +        prereqs="jxr:generate"/>
  +
  +  <!-- Should we deprecate it to use only 'jxr' ? -->
     <goal
  -    name="jxr:generate">
  +    name="jxr:generate"
  +    description="Generate HTML cross reference sources">
   
       <j:if test="${sourcesPresent == 'true'}">
   
  
  
  
  1.7       +7 -2      jakarta-turbine-maven/src/plugins/test/plugin.jelly
  
  Index: plugin.jelly
  ===================================================================
  RCS file: /home/cvs/jakarta-turbine-maven/src/plugins/test/plugin.jelly,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- plugin.jelly      6 Jul 2002 04:49:10 -0000       1.6
  +++ plugin.jelly      8 Jul 2002 16:47:25 -0000       1.7
  @@ -1,14 +1,18 @@
   
   <project xmlns:j="jelly:core">
   
  -  <goal name="test" prereqs="test:test"/>
  +  <goal name="test" 
  +        description="Test the application"
  +        prereqs="test:test"/>
   
  -  <goal name="test:prepare-filesystem">
  +  <goal name="test:prepare-filesystem"
  +        description="Create the needed directory structure">
       <mkdir dir="${maven.test.dest}"/>
       <mkdir dir="${maven.test.reportsDirectory}"/>
     </goal>
    
     <goal name="test:compile"
  +        description="Compile the TestCases and TestSuites"
           prereqs="java:compile,java:jar-resources,test:prepare-filesystem">
   
       <javac 
  @@ -29,6 +33,7 @@
     </goal>
   
     <goal name="test:test"
  +        description="Test the application"
           prereqs="test:compile">
   
       <junit printSummary="yes" 
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to