[Arakhnę-Dev] [384] * Make the exceptions in the Arakhne Mojo more detailled.

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


Revision: 384
Author:   galland
Date:     2012-08-24 16:08:19 +0200 (Fri, 24 Aug 2012)
Log Message:
-----------
* Make the exceptions in the Arakhne Mojo more detailled.

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

Modified: trunk/maventools/src/main/java/org/arakhne/maven/AbstractArakhneMojo.java
===================================================================
--- trunk/maventools/src/main/java/org/arakhne/maven/AbstractArakhneMojo.java	2012-08-20 22:46:17 UTC (rev 383)
+++ trunk/maventools/src/main/java/org/arakhne/maven/AbstractArakhneMojo.java	2012-08-24 14:08:19 UTC (rev 384)
@@ -1427,10 +1427,14 @@
 						}
 					}
 					catch (MojoExecutionException e) {
-						throw new NoSuchElementException(artifactId);
+						NoSuchElementException nsee = new NoSuchElementException(artifactId);
+						nsee.initCause(e);
+						throw nsee;
 					}
 					catch (ProjectBuildingException e) {
-						throw new NoSuchElementException(artifactId);
+						NoSuchElementException nsee = new NoSuchElementException(artifactId);
+						nsee.initCause(e);
+						throw nsee;
 					}
 				}
     		}

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	2012-08-20 22:46:17 UTC (rev 383)
+++ trunk/tag-replacer/src/main/java/org/arakhne/maven/plugins/tagreplacer/AbstractReplaceMojo.java	2012-08-24 14:08:19 UTC (rev 384)
@@ -742,7 +742,7 @@
 		StringBuilder buffer = new StringBuilder();
 		buffer.setLength(0);
 		// Split the string int "$" and "Id" to avoid the plugin to replace the tag in its own source fole
-		buffer.append("$"+"Id: "); //$NON-NLS-1$
+		buffer.append("$"+"Id: "); //$NON-NLS-1$ //$NON-NLS-2$
 		buffer.append(file);
 		buffer.append(' ');
 		if (replacementRevision != null) {


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