[Arakhnę-Dev] [270] * tag-replacer plugin must not force the using maven modules to override the {project .build.sourceDirectory}.

[ Thread Index | Date Index | More arakhne.org/dev Archives ]


Revision: 270
Author:   galland
Date:     2011-08-22 15:58:16 +0200 (Mon, 22 Aug 2011)
Log Message:
-----------
* tag-replacer plugin must not force the using maven modules to override the {project.build.sourceDirectory}. In place tag-replacer is silently proceeding this replacement inside the maven project under compilation.

Modified Paths:
--------------
    trunk/tag-replacer/src/main/java/org/arakhne/maven/plugins/tagreplacer/AbstractReplaceMojo.java

Modified: trunk/tag-replacer/src/main/java/org/arakhne/maven/plugins/tagreplacer/AbstractReplaceMojo.java
===================================================================
--- trunk/tag-replacer/src/main/java/org/arakhne/maven/plugins/tagreplacer/AbstractReplaceMojo.java	2011-08-22 12:19:46 UTC (rev 269)
+++ trunk/tag-replacer/src/main/java/org/arakhne/maven/plugins/tagreplacer/AbstractReplaceMojo.java	2011-08-22 13:58:16 UTC (rev 270)
@@ -33,7 +33,6 @@
 import java.nio.channels.WritableByteChannel;
 import java.nio.charset.Charset;
 import java.text.SimpleDateFormat;
-import java.util.Iterator;
 import java.util.List;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
@@ -145,11 +144,6 @@
 	private File sourceDirectory;
 
 	/**
-	 * @parameter expression="${project.build.sourceDirectory}"
-	 */
-	private File javaSourceRoot;
-
-	/**
 	 * @parameter expression="${project.build.directory}/generated-sources"
 	 */
 	private File generatedSourceDirectory;
@@ -630,7 +624,7 @@
 	 * @param newSourceDirectory
 	 */
 	protected void setSourceDirectoryForAllMojo(File newSourceDirectory) {
-		List<String> sourceRoots = this.mavenProject.getCompileSourceRoots();
+		/*List<String> sourceRoots = this.mavenProject.getCompileSourceRoots();
 		getLog().debug("Old source roots: "+sourceRoots.toString()); //$NON-NLS-1$
 		Iterator<String> iterator = sourceRoots.iterator();
 		String removableSourcePath = this.javaSourceRoot.getAbsolutePath();
@@ -645,7 +639,8 @@
 		}
 		getLog().debug("Adding source root: "+newSourceDirectory.getAbsolutePath()); //$NON-NLS-1$
 		this.mavenProject.addCompileSourceRoot(newSourceDirectory.toString());
-		this.sourceDirectory = newSourceDirectory;
+		this.sourceDirectory = newSourceDirectory;*/
+		getLog().warn("Change of the source roots is not yet supported"); //$NON-NLS-1$
 	}
 
 	/**


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/