maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From car...@apache.org
Subject svn commit: r349847 - /maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
Date Wed, 30 Nov 2005 00:06:32 GMT
Author: carlos
Date: Tue Nov 29 16:06:30 2005
New Revision: 349847

URL: http://svn.apache.org/viewcvs?rev=349847&view=rev
Log:
Refactor

Modified:
    maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java

Modified: maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
URL: http://svn.apache.org/viewcvs/maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java?rev=349847&r1=349846&r2=349847&view=diff
==============================================================================
--- maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
(original)
+++ maven/plugins/trunk/maven-antrun-plugin/src/main/java/org/apache/maven/plugin/antrun/AbstractAntMojo.java
Tue Nov 29 16:06:30 2005
@@ -37,35 +37,34 @@
     protected void executeTasks( Target antTasks, MavenProject mavenProject )
         throws MojoExecutionException
     {
-    	try
+        try
         {
-            PropertyHelper propertyHelper = PropertyHelper.getPropertyHelper(
-                antTasks.getProject()
-            );
+            Project antProject = antTasks.getProject();
 
-            propertyHelper.setNext(
-                new AntPropertyHelper( mavenProject, getLog() )
-            );
+            PropertyHelper propertyHelper = PropertyHelper.getPropertyHelper( antProject
);
+
+            propertyHelper.setNext( new AntPropertyHelper( mavenProject, getLog() ) );
 
             DefaultLogger antLogger = new DefaultLogger();
             antLogger.setOutputPrintStream( System.out );
             antLogger.setErrorPrintStream( System.err );
             antLogger.setMessageOutputLevel( Project.MSG_INFO );
 
-            antTasks.getProject().addBuildListener( antLogger );
-            antTasks.getProject().setBaseDir( mavenProject.getBasedir() );
+            antProject.addBuildListener( antLogger );
+            antProject.setBaseDir( mavenProject.getBasedir() );
 
-            Path p = new Path( antTasks.getProject() );
+            Path p = new Path( antProject );
             p.setPath( StringUtils.join( mavenProject.getArtifacts().iterator(), File.pathSeparator
) );
-            antTasks.getProject().addReference( "maven.dependency.classpath", p );
+            antProject.addReference( "maven.dependency.classpath", p );
+            p = new Path( antProject );
             p.setPath( StringUtils.join( mavenProject.getCompileClasspathElements().iterator(),
File.pathSeparator ) );
-            antTasks.getProject().addReference( "maven.compile.classpath", p );
-            p = new Path( antTasks.getProject() );
+            antProject.addReference( "maven.compile.classpath", p );
+            p = new Path( antProject );
             p.setPath( StringUtils.join( mavenProject.getRuntimeClasspathElements().iterator(),
File.pathSeparator ) );
-            antTasks.getProject().addReference( "maven.runtime.classpath", p );
-            p = new Path( antTasks.getProject() );
+            antProject.addReference( "maven.runtime.classpath", p );
+            p = new Path( antProject );
             p.setPath( StringUtils.join( mavenProject.getTestClasspathElements().iterator(),
File.pathSeparator ) );
-            antTasks.getProject().addReference( "maven.test.classpath", p );
+            antProject.addReference( "maven.test.classpath", p );
 
             getLog().info( "Executing tasks" );
 



Mime
View raw message