servicemix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ge...@apache.org
Subject svn commit: r1028118 - in /servicemix/documentation/trunk: pom.xml src/main/ant/generate-pdfs.xml
Date Wed, 27 Oct 2010 21:57:19 GMT
Author: gertv
Date: Wed Oct 27 21:57:18 2010
New Revision: 1028118

URL: http://svn.apache.org/viewvc?rev=1028118&view=rev
Log:
Allow running documentation build without Prince installed

Modified:
    servicemix/documentation/trunk/pom.xml
    servicemix/documentation/trunk/src/main/ant/generate-pdfs.xml

Modified: servicemix/documentation/trunk/pom.xml
URL: http://svn.apache.org/viewvc/servicemix/documentation/trunk/pom.xml?rev=1028118&r1=1028117&r2=1028118&view=diff
==============================================================================
--- servicemix/documentation/trunk/pom.xml (original)
+++ servicemix/documentation/trunk/pom.xml Wed Oct 27 21:57:18 2010
@@ -44,6 +44,9 @@
     <webapp.dir>${project.build.directory}/webapp</webapp.dir>
 
     <maven.wagon.version>1.0-beta-6</maven.wagon.version>
+
+    <pdf.required>false</pdf.required>
+
     <scalate.version>1.4-SNAPSHOT</scalate.version>
     <scalate.mode>production</scalate.mode>
     <scalate.workdir>${basedir}/target/scalateWorkDir</scalate.workdir>
@@ -274,7 +277,9 @@
             <configuration>
               <tasks>
                 <ant antfile="${project.basedir}/src/main/ant/generate-pdfs.xml"
-                     dir="${project.basedir}"/>
+                     dir="${project.basedir}">
+                  <property name="pdf.required" value="${pdf.required}"/>
+                </ant>
             </tasks>
             </configuration>
             <goals>
@@ -285,35 +290,6 @@
         </executions>
       </plugin>
 
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>build-helper-maven-plugin</artifactId>
-        <version>1.5</version>
-        <executions>
-          <execution>
-            <id>attach-artifacts</id>
-            <phase>verify</phase>
-            <goals>
-              <goal>attach-artifact</goal>
-            </goals>
-            <configuration>
-              <artifacts>
-                <artifact>
-                  <file>${project.build.directory}/sitegen/users-guide/manual.pdf</file>
-                  <type>pdf</type>
-                  <classifier>users-guide</classifier>
-                </artifact>
-                <artifact>
-                  <file>${project.build.directory}/sitegen/jbi/jbi-guide.pdf</file>
-                  <type>pdf</type>
-                  <classifier>jbi-guide</classifier>
-                </artifact>                
-              </artifacts>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-
     </plugins>
   </build>
   
@@ -345,5 +321,47 @@
     </pluginRepository>
   </pluginRepositories>
 
+
+    <profiles>
+        <profile>
+            <id>apache-release</id>
+            <properties>
+                <pdf.required>true</pdf.required>
+            </properties>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.codehaus.mojo</groupId>
+                        <artifactId>build-helper-maven-plugin</artifactId>
+                        <version>1.5</version>
+                        <executions>
+                            <execution>
+                                <id>attach-artifacts</id>
+                                <phase>verify</phase>
+                                <goals>
+                                    <goal>attach-artifact</goal>
+                                </goals>
+                                <configuration>
+                                    <artifacts>
+                                        <artifact>
+                                            <file>${project.build.directory}/sitegen/users-guide/manual.pdf</file>
+                                            <type>pdf</type>
+                                            <classifier>users-guide</classifier>
+                                        </artifact>
+                                        <artifact>
+                                            <file>${project.build.directory}/sitegen/jbi/jbi-guide.pdf</file>
+                                            <type>pdf</type>
+                                            <classifier>jbi-guide</classifier>
+                                        </artifact>
+                                    </artifacts>
+                                </configuration>
+                            </execution>
+                        </executions>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+    </profiles>
+
 </project>
 

Modified: servicemix/documentation/trunk/src/main/ant/generate-pdfs.xml
URL: http://svn.apache.org/viewvc/servicemix/documentation/trunk/src/main/ant/generate-pdfs.xml?rev=1028118&r1=1028117&r2=1028118&view=diff
==============================================================================
--- servicemix/documentation/trunk/src/main/ant/generate-pdfs.xml (original)
+++ servicemix/documentation/trunk/src/main/ant/generate-pdfs.xml Wed Oct 27 21:57:18 2010
@@ -28,14 +28,15 @@
     <attribute name="input" default="${sitegen}/@{document}.html"/>
     <attribute name="output" default="${sitegen}/@{document}.pdf"/>
     <sequential>
-      <echo message="Running Prince XML (http://princexml.com) on @{input}" />
-      <exec executable="prince">
+      <echo message="Running Prince XML (http://princexml.com)" />
+      <echo message=" converting @{input}"/>
+      <echo message="       into @{output}"/>
+      <exec executable="prince" failifexecutionfails="${pdf.required}">
         <arg value="@{input}" />
         <arg value="@{output}" />
         <arg value="--log"/>
         <arg value="${target}/prince.log"/>
       </exec>
-      <echo  message="Successfully created @{output}"/>      
     </sequential>
   </macrodef>
 



Mime
View raw message