Author: andy
Date: Thu Mar 29 07:17:48 2012
New Revision: 1306728

URL: http://svn.apache.org/viewvc?rev=1306728&view=rev
Log:
Use maven property for timestamp, not an ant task.

Modified:
    incubator/jena/Jena2/ARQ/trunk/pom.xml
    incubator/jena/Jena2/Fuseki/trunk/pom.xml
    incubator/jena/Jena2/TDB/trunk/pom.xml

Modified: incubator/jena/Jena2/ARQ/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/jena/Jena2/ARQ/trunk/pom.xml?rev=1306728&r1=1306727&r2=1306728&view=diff
==============================================================================
--- incubator/jena/Jena2/ARQ/trunk/pom.xml (original)
+++ incubator/jena/Jena2/ARQ/trunk/pom.xml Thu Mar 29 07:17:48 2012
@@ -48,6 +48,8 @@
     <ver.httpclient>4.1.2</ver.httpclient>
     <ver.httpcore>4.1.3</ver.httpcore>
     <ver.commons-codec>1.5</ver.commons-codec>
+    
<maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ssZ</maven.build.timestamp.format>
+    <build.time.xsd>${maven.build.timestamp}</build.time.xsd>
   </properties>
 
   <dependencies>
@@ -102,11 +104,6 @@
   </dependencies>
 
   <build>
-    <!-- The filter file is written by antrun -->
-    <filters>
-      <filter>${project.basedir}/target/filter.properties</filter>
-    </filters>
-
     <resources>
       <resource>
         <filtering>false</filtering>
@@ -201,39 +198,6 @@
         <artifactId>maven-resources-plugin</artifactId>
       </plugin>
 
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-antrun-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>ant-timestamp</id>
-            <phase>initialize</phase>
-            <configuration>
-              <target>
-                <mkdir dir="${project.basedir}/target" />
-                <tstamp>
-                  <format property="build.time.xsd" 
pattern="yyyy-MM-dd'T'HH:mm:ssZ" />
-                  <format property="build.time.txt" pattern="yyyy-MM-dd HH:mm 
z" />
-                </tstamp>
-                <!-- Do not indent (it does not work) -->
-                <echo file="${project.basedir}/target/filter.properties">
-#begin
-build.time.xsd=${build.time.xsd}
-build.time.txt=${build.time.txt}
-#end
-                </echo>
-                <echo message="version=${project.version}" />
-                <echo message="build.time=${build.time.txt}" />
-              </target>
-            </configuration>
-            <goals>
-              <goal>run</goal>
-            </goals>
-          </execution>
-          <!-- Another task, another execution -->
-        </executions>
-      </plugin>
-
       <!--
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>

Modified: incubator/jena/Jena2/Fuseki/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/jena/Jena2/Fuseki/trunk/pom.xml?rev=1306728&r1=1306727&r2=1306728&view=diff
==============================================================================
--- incubator/jena/Jena2/Fuseki/trunk/pom.xml (original)
+++ incubator/jena/Jena2/Fuseki/trunk/pom.xml Thu Mar 29 07:17:48 2012
@@ -74,6 +74,9 @@
     <ver.commons-codec>1.5</ver.commons-codec>
     <ver.slf4j>1.6.4</ver.slf4j>
     <ver.log4j>1.2.16</ver.log4j>
+    
+    
<maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ssZ</maven.build.timestamp.format>
+    <build.time.xsd>${maven.build.timestamp}</build.time.xsd>
   </properties>
 
   <dependencies>
@@ -234,46 +237,8 @@
         </includes>
       </resource>
     </resources>
-    <filters>
-      <filter>${project.basedir}/target/filter.properties</filter>
-    </filters>
     
     <plugins>
-      <!-- This produce a java properties file 'filter.properties' with 
timestanps in
-           For use with fileritng resources.
-      -->
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-antrun-plugin</artifactId>
-        
-        <executions>
-          <execution>
-            <id>ant-generate-resources</id>
-            <phase>generate-resources</phase>
-            <configuration>
-              <target>
-                <mkdir dir="${project.basedir}/target" />
-                <tstamp>
-                  <format property="build.time.xsd" 
pattern="yyyy-MM-dd'T'HH:mm:ssZ" />
-                  <format property="build.time.txt" pattern="yyyy-MM-dd HH:mm 
Z" />
-                </tstamp>
-                <echo file="${project.basedir}/target/filter.properties">
-                  #begin
-                  build.time.xsd=${build.time.xsd}
-                  build.time.txt=${build.time.txt}
-                  #end
-                </echo>
-                <echo message="Version = ${project.version}" />
-                <echo message="build.time=${build.time.txt}" />
-              </target>
-            </configuration>
-            <goals>
-              <goal>run</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-      
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-compiler-plugin</artifactId>

Modified: incubator/jena/Jena2/TDB/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/jena/Jena2/TDB/trunk/pom.xml?rev=1306728&r1=1306727&r2=1306728&view=diff
==============================================================================
--- incubator/jena/Jena2/TDB/trunk/pom.xml (original)
+++ incubator/jena/Jena2/TDB/trunk/pom.xml Thu Mar 29 07:17:48 2012
@@ -44,7 +44,10 @@
 
     <ver.jena>2.7.1-incubating-SNAPSHOT</ver.jena>
     <ver.arq>2.9.1-incubating-SNAPSHOT</ver.arq>
-
+    
+    
<maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ssZ</maven.build.timestamp.format>
+    <build.time.xsd>${maven.build.timestamp}</build.time.xsd>
+ 
   </properties>
 
   <!-- Testing against staged artifacts - ->
@@ -95,24 +98,20 @@
   <build>
     <resources>
       <resource>
-       <filtering>false</filtering>
-       <directory>src/main/resources</directory>
-       <excludes>
-         <exclude>org/apache/jena/tdb/tdb-properties.xml</exclude>
-       </excludes>
+        <filtering>false</filtering>
+        <directory>src/main/resources</directory>
+        <excludes>
+          <exclude>org/apache/jena/tdb/tdb-properties.xml</exclude>
+        </excludes>
       </resource>
       <resource>
-       <filtering>true</filtering>
-       <directory>src/main/resources</directory>
-       <includes>
-         <include>org/apache/jena/tdb/tdb-properties.xml</include>
-       </includes>
+        <filtering>true</filtering>
+        <directory>src/main/resources</directory>
+        <includes>
+          <include>org/apache/jena/tdb/tdb-properties.xml</include>
+        </includes>
       </resource>
     </resources>
-    <!-- The filter file is written by antrun -->
-    <filters>
-      <filter>${project.basedir}/target/filter.properties</filter>
-    </filters>
 
     <plugins>
       <plugin>
@@ -141,19 +140,19 @@
               <goal>jar-no-fork</goal> 
             </goals>
           </execution>
-         <!-- Don't release test support code
+          <!-- Don't release test support code
           <execution>
             <id>attach-sources-test</id>
             <goals>
               <goal>test-jar-no-fork</goal>
             </goals>
           </execution>
-         -->
+          -->
         </executions>
       
       </plugin>
 
-       <!-- Don't release test code
+      <!-- Don't release test code
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-jar-plugin</artifactId>
@@ -188,68 +187,35 @@
       </plugin>
       
       <plugin>
+        <!-- This must be the last plug-in attached to the package phase 
+             because it replies on the packaging of the jar to happen first.
+        -->
         <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-antrun-plugin</artifactId>
+
+        <artifactId>maven-assembly-plugin</artifactId>
         <executions>
           <execution>
-            <id>ant-timestamp</id>
-            <phase>generate-resources</phase>
+            <id>create-assembly</id>
+            <phase>package</phase>
+            <goals><goal>single</goal></goals>
             <configuration>
-              <target>
-                <mkdir dir="${project.basedir}/target" />
-                <tstamp>
-                  <format property="build.time.xsd" 
pattern="yyyy-MM-dd'T'HH:mm:ssZ" />
-                  <format property="build.time.txt" pattern="yyyy-MM-dd HH:mm 
z" />
-                </tstamp>
-                <!-- Do not indent (it does not work) -->
-                <echo file="${project.basedir}/target/filter.properties">
-#begin
-build.time.xsd=${build.time.xsd}
-build.time.txt=${build.time.txt}
-#end
-                </echo>
-                <echo message="version=${project.version}" />
-                <echo message="build.time=${build.time.txt}" />
-              </target>
+              <!-- If you place this in target/ directly - it will be 
+                   uploaded to the repo AND its name is changed
+                   to the group-artifact name (this can overwrite, silently,
+                   other files.
+              -->
+              <!--
+              <finalName>dist/${assembly.root.name}</finalName>
+              <appendAssemblyId>false</appendAssemblyId>
+              -->
+              <descriptors>
+                <descriptor>assembly.xml</descriptor>
+              </descriptors>
             </configuration>
-            <goals>
-              <goal>run</goal>
-            </goals>
           </execution>
-          <!-- Another task, another execution -->
         </executions>
       </plugin>
 
-      <plugin>
-       <!-- This must be the last plug-in attached to the package phase 
-            because it replies on the packaging of the jar to happen first.
-       -->
-       <groupId>org.apache.maven.plugins</groupId>
-
-       <artifactId>maven-assembly-plugin</artifactId>
-       <executions>
-         <execution>
-           <id>create-assembly</id>
-           <phase>package</phase>
-           <goals><goal>single</goal></goals>
-           <configuration>
-             <!-- If you place this in target/ directly - it will be 
-                  uploaded to the repo AND its name is changed
-                  to the group-artifact name (this can overwrite, silently,
-                  other files.
-             -->
-             <!--
-             <finalName>dist/${assembly.root.name}</finalName>
-             <appendAssemblyId>false</appendAssemblyId>
-             -->
-             <descriptors>
-               <descriptor>assembly.xml</descriptor>
-             </descriptors>
-           </configuration>
-         </execution>
-       </executions>
-      </plugin>
-
     </plugins>
   </build>
 


Reply via email to