maven-m2-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jvan...@apache.org
Subject cvs commit: maven-components/maven-core/src/main/java/org/apache/maven/lifecycle DefaultLifecycleExecutor.java
Date Sun, 13 Mar 2005 23:52:43 GMT
jvanzyl     2005/03/13 15:52:43

  Modified:    maven-core/src/main/java/org/apache/maven/lifecycle
                        DefaultLifecycleExecutor.java
  Log:
  o fixing construction of mojo descriptor id
  
  Revision  Changes    Path
  1.22      +10 -3     maven-components/maven-core/src/main/java/org/apache/maven/lifecycle/DefaultLifecycleExecutor.java
  
  Index: DefaultLifecycleExecutor.java
  ===================================================================
  RCS file: /home/cvs/maven-components/maven-core/src/main/java/org/apache/maven/lifecycle/DefaultLifecycleExecutor.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -r1.21 -r1.22
  --- DefaultLifecycleExecutor.java	12 Mar 2005 21:54:21 -0000	1.21
  +++ DefaultLifecycleExecutor.java	13 Mar 2005 23:52:43 -0000	1.22
  @@ -223,18 +223,25 @@
           // mojos the user has specified and ignore the rest.
           // ----------------------------------------------------------------------
   
  -
           if ( plugin.getGoals().size() > 0 )
           {
               String pluginId = pluginDescriptor.getArtifactId();
   
  -            pluginId = pluginId.substring( 6 ).substring( 0, 7 );
  +            // Right now this maven-foo-plugin so this is a hack right now.
  +
  +            pluginId = pluginId.substring( 6 );
  +
  +            pluginId = pluginId.substring( 0, pluginId.lastIndexOf( "-" ) );
   
               for ( Iterator i = plugin.getGoals().iterator(); i.hasNext(); )
               {
                   Goal goal = (Goal) i.next();
   
  -                configureMojo( pluginManager.getMojoDescriptor( pluginId + ":" + goal.getId()
) );
  +                String mojoId = pluginId + ":" + goal.getId();
  +
  +                MojoDescriptor mojoDescriptor = pluginManager.getMojoDescriptor( mojoId
);
  +
  +                configureMojo( mojoDescriptor );
               }
           }
           else
  
  
  

Mime
View raw message