incubator-odf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From svanteschub...@apache.org
Subject svn commit: r1387530 - in /incubator/odf/trunk: .gitignore validator/pom.xml validator/src/main/assembly/ validator/src/main/assembly/src.xml validator/src/main/java/org/odftoolkit/odfvalidator/Main.java
Date Wed, 19 Sep 2012 11:38:13 GMT
Author: svanteschubert
Date: Wed Sep 19 11:38:12 2012
New Revision: 1387530

URL: http://svn.apache.org/viewvc?rev=1387530&view=rev
Log:
.gitignore & Validator patches from Michael Stahl (jar access via command-line & help
docu fixes)

Added:
    incubator/odf/trunk/.gitignore
    incubator/odf/trunk/validator/src/main/assembly/
    incubator/odf/trunk/validator/src/main/assembly/src.xml
Modified:
    incubator/odf/trunk/validator/pom.xml
    incubator/odf/trunk/validator/src/main/java/org/odftoolkit/odfvalidator/Main.java

Added: incubator/odf/trunk/.gitignore
URL: http://svn.apache.org/viewvc/incubator/odf/trunk/.gitignore?rev=1387530&view=auto
==============================================================================
--- incubator/odf/trunk/.gitignore (added)
+++ incubator/odf/trunk/.gitignore Wed Sep 19 11:38:12 2012
@@ -0,0 +1,7 @@
+*.class
+.DS_Store
+bin/
+target/
+*~
+.*sw?
+\#*
\ No newline at end of file

Modified: incubator/odf/trunk/validator/pom.xml
URL: http://svn.apache.org/viewvc/incubator/odf/trunk/validator/pom.xml?rev=1387530&r1=1387529&r2=1387530&view=diff
==============================================================================
--- incubator/odf/trunk/validator/pom.xml (original)
+++ incubator/odf/trunk/validator/pom.xml Wed Sep 19 11:38:12 2012
@@ -48,13 +48,13 @@
 		<maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ss</maven.build.timestamp.format>
 	</properties>
 
-  <!--
-    The POM of org.iso_relax.verifier.jaxp.validation:isorelax-jaxp-bridge:jar:1.0
-    on the central repo is not 4.0.0 complaint so that we should pick the one SMX
-    Repo already provides, as otherwise building under Maven 3.0.4 would fail!
-    So delete any old .m2 cache entries of yours for this artifact beforehand if
-    you make use of Maven 3.0.4+
-  -->
+	<!--
+   The POM of org.iso_relax.verifier.jaxp.validation:isorelax-jaxp-bridge:jar:1.0
+   on the central repo is not 4.0.0 complaint so that we should pick the one SMX
+   Repo already provides, as otherwise building under Maven 3.0.4 would fail!
+   So delete any old .m2 cache entries of yours for this artifact beforehand if
+   you make use of Maven 3.0.4+
+ -->
 	<repositories>
 		<repository>
 			<id>apache.smx.repo</id>
@@ -69,7 +69,7 @@
 		</repository>
 	</repositories>
 
-    <!-- Build Settings -->
+	<!-- Build Settings -->
 	<build>
 		<extensions>
 			<extension>
@@ -254,6 +254,18 @@
 				<configuration>
 					<archive>
 						<index>true</index>
+						<!--  No custom manifest worked, neither the below..
+							<index>true</index>
+							<manifest>
+								<addClasspath>true</addClasspath>
+								<odfdomName>ODFDOM Validator</odfdomName>
+								<odfdomVersion>${project.version}</odfdomVersion>
+								<odfdomWebsite>http://incubator.apache.org/odftoolkit/conformance/ODFValidator.html</odfdomWebsite>
+								<odfdomBuiltDate>${build.timestamp}</odfdomBuiltDate>
+								<odfdomSupportedOdfVersion>1.2</odfdomSupportedOdfVersion>
+								<mainClass>org.odftoolkit.odfvalidator.Main</mainClass>
+							</manifest>
+						</archive>-->
 						<manifestEntries>
 							<version>${project.version}</version>
 						</manifestEntries>
@@ -276,14 +288,14 @@
 				<artifactId>maven-release-plugin</artifactId>
 				<version>2.1</version>
 				<configuration>
-                    <!-- Workaround for http://jira.codehaus.org/browse/MGPG-9 -->
+					<!-- Workaround for http://jira.codehaus.org/browse/MGPG-9 -->
 					<mavenExecutorId>forked-path</mavenExecutorId>
 				</configuration>
 			</plugin>
 			<plugin>
 				<groupId>org.apache.maven.plugins</groupId>
 				<artifactId>maven-surefire-plugin</artifactId>
-                <!-- Explizit version required for fix on systemPropertyVariables -->
+				<!-- Explizit version required for fix on systemPropertyVariables -->
 				<version>2.6</version>
 				<configuration>
 					<systemPropertyVariables>
@@ -308,9 +320,15 @@
 			<plugin>
 				<artifactId>maven-assembly-plugin</artifactId>
 				<configuration>
-					<descriptorRefs>
-						<descriptorRef>jar-with-dependencies</descriptorRef>
-					</descriptorRefs>
+					<archive>
+						<manifestEntries>							
+							<version>${project.version}</version>
+							<Main-Class>org.odftoolkit.odfvalidator.Main</Main-Class>
+						</manifestEntries>
+					</archive>
+					<descriptors>					
+						<descriptor>src/main/assembly/src.xml</descriptor>
+					</descriptors>
 				</configuration>
 				<executions>
 					<execution>
@@ -336,7 +354,7 @@
 	</build>
 	<reporting>
 		<plugins>
-            <!-- Code Coverage Testing generated by Cobertura -->
+			<!-- Code Coverage Testing generated by Cobertura -->
 			<plugin>
 				<groupId>org.codehaus.mojo</groupId>
 				<artifactId>cobertura-maven-plugin</artifactId>
@@ -350,7 +368,7 @@
 				</configuration>
 			</plugin>
             
-            <!-- Reporting integration test results -->
+			<!-- Reporting integration test results -->
 			<plugin>
 				<groupId>org.apache.maven.plugins</groupId>
 				<artifactId>maven-failsafe-plugin</artifactId>
@@ -370,11 +388,11 @@
 		</plugins>
 	</reporting>
 
-    <!-- More Project Information -->
+	<!-- More Project Information -->
 	<name>ODF Validator</name>
 	<description>
-        ODF Validator is a tool that validates OpenDocument files and checks them for certain
conformance criteria.
-    </description>
+		ODF Validator is a tool that validates OpenDocument files and checks them for certain conformance
criteria.
+	</description>
 	<url>http://incubator.apache.org/odftoolkit/conformance/ODFValidator.html</url>
 	<inceptionYear>2008</inceptionYear>
 	<licenses>
@@ -510,7 +528,7 @@
 		</developer>
 	</developers>
 
-    <!-- Environment Settings -->
+	<!-- Environment Settings -->
 	<issueManagement>
 		<system>JIRA</system>
 		<url>https://issues.apache.org/jira/browse/ODFTOOLKIT</url>
@@ -542,14 +560,14 @@
 		<developerConnection>scm:svn:https://svn.apache.org/repos/asf/incubator/odf/trunk/validator</developerConnection>
 		<url>http://svn.apache.org/viewvc/incubator/odf/trunk/validator</url>
 	</scm>
-    <!-- Upload of JAVA DOC for SNAPSHOOTs
-    <distributionManagement>
-        <site>
-            <id>odfdom</id>
-            <name>ODFDOM Java Toolkit Project</name>
-            <url>dav:https://odftoolkit.org/website/odfdom/${project.version}</url>
-        </site>
-    </distributionManagement> -->
+	<!-- Upload of JAVA DOC for SNAPSHOOTs
+ <distributionManagement>
+  <site>
+   <id>odfdom</id>
+   <name>ODFDOM Java Toolkit Project</name>
+   <url>dav:https://odftoolkit.org/website/odfdom/${project.version}</url>
+  </site>
+ </distributionManagement> -->
 	<profiles>
 		<profile>
 			<id>integration-test</id>
@@ -587,7 +605,7 @@
 					<plugin>
 						<groupId>org.apache.maven.plugins</groupId>
 						<artifactId>maven-surefire-plugin</artifactId>
-                        <!-- Explizit version required for fix on systemPropertyVariables
-->
+						<!-- Explizit version required for fix on systemPropertyVariables -->
 						<version>2.6</version>
 						<configuration>
 							<systemPropertyVariables>
@@ -601,13 +619,13 @@
 				</plugins>
 			</build>
 		</profile>
-    <!-- Profile for deploying to the Sonatype repository, which
-         requires GPG signatures 
-         see
-         https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide
-         https://docs.sonatype.org/display/Repository/How+To+Generate+PGP+Signatures+With+Maven
-         https://issues.sonatype.org/browse/OSSRH-960
-         -->
+		<!-- Profile for deploying to the Sonatype repository, which
+  requires GPG signatures 
+  see
+  https://docs.sonatype.org/display/Repository/Sonatype+OSS+Maven+Repository+Usage+Guide
+  https://docs.sonatype.org/display/Repository/How+To+Generate+PGP+Signatures+With+Maven
+  https://issues.sonatype.org/browse/OSSRH-960
+  -->
 		<profile>
 			<id>release-sign-artifacts</id>
 			<activation>

Added: incubator/odf/trunk/validator/src/main/assembly/src.xml
URL: http://svn.apache.org/viewvc/incubator/odf/trunk/validator/src/main/assembly/src.xml?rev=1387530&view=auto
==============================================================================
--- incubator/odf/trunk/validator/src/main/assembly/src.xml (added)
+++ incubator/odf/trunk/validator/src/main/assembly/src.xml Wed Sep 19 11:38:12 2012
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
+		  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+		  xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0
http://maven.apache.org/xsd/assembly-1.1.0.xsd">
+	<!-- TODO: a jarjar format would be better -->
+	<id>jar-with-dependencies</id>
+	<formats>
+		<format>jar</format>
+	</formats>
+	<includeBaseDirectory>false</includeBaseDirectory>
+	<dependencySets>
+		<dependencySet>
+			<outputDirectory>/</outputDirectory>
+			<useProjectArtifact>true</useProjectArtifact>
+			<unpack>true</unpack>
+			<scope>runtime</scope>
+		</dependencySet>
+	</dependencySets>
+	<!-- customization: add classes (wtf isn't this included by default?) -->
+	<fileSets>
+		<fileSet>
+			<outputDirectory>/</outputDirectory>
+			<directory>${basedir}/target/classes</directory>
+			<useDefaultExcludes>true</useDefaultExcludes>
+		</fileSet>
+	</fileSets>
+</assembly>

Modified: incubator/odf/trunk/validator/src/main/java/org/odftoolkit/odfvalidator/Main.java
URL: http://svn.apache.org/viewvc/incubator/odf/trunk/validator/src/main/java/org/odftoolkit/odfvalidator/Main.java?rev=1387530&r1=1387529&r2=1387530&view=diff
==============================================================================
--- incubator/odf/trunk/validator/src/main/java/org/odftoolkit/odfvalidator/Main.java (original)
+++ incubator/odf/trunk/validator/src/main/java/org/odftoolkit/odfvalidator/Main.java Wed
Sep 19 11:38:12 2012
@@ -152,7 +152,7 @@ public class Main {
             else if( aArg.startsWith("-") )
             {
                 System.out.print(aArg);
-                System.out.println(": unknown option, use '-' for help");
+                System.out.println(": unknown option, use '-h' for help");
                 return;
             }
             else if( aArg.length()>0 )
@@ -278,12 +278,12 @@ public class Main {
         System.out.println( "-h: Print this help and exit" );
         System.out.println( "-o: Store validation errors in <outputfile>" );
         System.out.println( "-r: Process directory recursively" );
-        System.out.println( "-s: Validate against strict schema (ODF 1.2 documents only)"
);
+        System.out.println( "-s: Validate against strict schema (ODF 1.0/1.1 documents only)"
);
         System.out.println( "-v: Verbose output, including generator and warnings" );
         System.out.println( "-w: Print warnings" );
         System.out.println( "-x: Exclude paths that match <regexp>" );
         System.out.println();
-        System.out.println( "If no option is provided, <odffiles> are validated using
<schemafile>" );
+        System.out.println( "If no option is provided, <odffiles> are validated using
the schemas matching the detected ODF version of the files" );
     }
 
 }



Mime
View raw message