Permalink
Browse files

Merge branch 'master' of https://github.com/vietj/wikbook

  • Loading branch information...
2 parents eb51ed7 + 4399293 commit 76e6297c546ec0422ddbc82678515d70ba191106 @dbaeli committed Jan 27, 2012
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -133,6 +133,7 @@
<copy todir="\${wikbook.target}/output/html">
<fileset dir="\${wikbook.target}/src/resources/">
<include name="**/*.css"/>
+ <include name="**/*.js"/>
<include name="**/*.png"/>
<include name="**/*.js"/>
<include name="**/*.gif"/>
@@ -168,6 +169,7 @@
<copy todir="\${wikbook.target}/output/xhtml">
<fileset dir="\${wikbook.target}/src/resources/">
<include name="**/*.css"/>
+ <include name="**/*.js"/>
<include name="**/*.png"/>
<include name="**/*.gif"/>
<include name="**/*.jpg"/>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -43,9 +43,29 @@
*/
public final void onValidationError(String msg)
{
+ onValidationError(msg, null);
+ }
+
+ /**
+ * The behavior of this method depends on the context validation mode.
+ * @param t the throwable
+ */
+ public final void onValidationError(Throwable t)
+ {
+ onValidationError(t.getMessage(), t);
+ }
+
+ /**
+ * The behavior of this method depends on the context validation mode.
+ *
+ * @param msg the message
+ * @param t the throwable
+ */
+ public final void onValidationError(String msg, Throwable t)
+ {
if (getValidationMode() == ValidationMode.STRICT)
{
- throw new WikbookValidationException(msg);
+ throw new WikbookValidationException(msg, t);
}
else
{
@@ -197,7 +197,7 @@ private void performIncludes(Element elt)
}
catch (Exception e)
{
- e.printStackTrace();
+ context.onValidationError(e);
Element errorElt = elt.getOwnerDocument().createElement("wikbook:error");
Text text = elt.getOwnerDocument().createTextNode(e.getMessage());
errorElt.appendChild(text);
@@ -274,7 +274,7 @@ public void process()
}
catch (Exception e)
{
- e.printStackTrace();
+ context.onValidationError(e);
bilto = "Exception occured, see logs";
}
break;
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -58,6 +58,7 @@
<emitDoctype>true</emitDoctype>
<beforeBookBodyXML><![CDATA[<xi:include href="bookinfo.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />]]></beforeBookBodyXML>
<bookId>index</bookId>
+ <validationMode>strict</validationMode>
</configuration>
</plugin>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -45,10 +45,7 @@
import java.net.URL;
import java.net.URLClassLoader;
import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
import java.util.Collections;
-import java.util.Enumeration;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Properties;
View
32 pom.xml
@@ -5,7 +5,7 @@
<groupId>org.wikbook</groupId>
<artifactId>wikbook.parent</artifactId>
<packaging>pom</packaging>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
<name>Wikbook parent</name>
<description>The Wikbook project</description>
@@ -93,59 +93,59 @@
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.codesource</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.core</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.xwiki</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.maven</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.docbkxstyle</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.doc</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.doc</artifactId>
<classifier>html</classifier>
<type>zip</type>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.template</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.template.core</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.template.test-processor</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.template.test-processing</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</dependency>
<dependency>
@@ -216,7 +216,6 @@
<artifactId>xwiki-rendering-syntax-xwiki2</artifactId>
<version>3.2</version>
</dependency>
-
</dependencies>
</dependencyManagement>
@@ -270,13 +269,18 @@
<plugin>
<groupId>org.wikbook</groupId>
<artifactId>wikbook.maven</artifactId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</plugin>
<plugin>
<groupId>com.github.github</groupId>
<artifactId>site-maven-plugin</artifactId>
<version>0.3</version>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.9</version>
+ </plugin>
</plugins>
</pluginManagement>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.template</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.template</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.template</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
View
@@ -3,7 +3,7 @@
<parent>
<artifactId>wikbook.parent</artifactId>
<groupId>org.wikbook</groupId>
- <version>0.9.37-SNAPSHOT</version>
+ <version>0.9.38-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
@@ -63,6 +63,17 @@
<directory>src/test/resources</directory>
</testResource>
</testResources>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <systemPropertyVariables>
+ <targetDir>${project.build.directory}</targetDir>
+ </systemPropertyVariables>
+ </configuration>
+ </plugin>
+ </plugins>
</build>
</project>
Oops, something went wrong.

0 comments on commit 76e6297

Please sign in to comment.