cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r405584 - in /incubator/cayenne/main/trunk/cayenne/cayenne-ant: ant/doc.xml ant/import/paths.xml build.xml
Date Wed, 10 May 2006 01:13:01 GMT
Author: aadamchik
Date: Tue May  9 18:12:59 2006
New Revision: 405584

URL: http://svn.apache.org/viewcvs?rev=405584&view=rev
Log:
switching ant scripts to make docs out of confluence data.

Modified:
    incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/doc.xml
    incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/import/paths.xml
    incubator/cayenne/main/trunk/cayenne/cayenne-ant/build.xml

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/doc.xml
URL: http://svn.apache.org/viewcvs/incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/doc.xml?rev=405584&r1=405583&r2=405584&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/doc.xml (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/doc.xml Tue May  9 18:12:59 2006
@@ -4,48 +4,46 @@
 <!--         Cayenne documentation buildfile.          -->
 <!-- ================================================= -->
 <project>
-	
-	<!-- can't use common build folder, as Anakia requires relative path -->
-	<property name="build.suffix" value="build/ant/docs"/>
-	<property name="build.docs" value="${cayenne.other}/${build.suffix}"/>
-	<property name="build.pdf" value="${build.docs}/classes"/>
-	<property name="xdocs" value="${cayenne.other}/xdocs"/>
+	<property name="core.build.tools" value="${build}/tools/classes"/>
 	<property name="parser.dir.exp"
 		value="${cayenne.java}/src/cayenne/java/org/objectstyle/cayenne/exp/parser"/>
 	<property name="parser.base.exp" value="ExpressionParser"/>
 	
 	<!-- ========================================== -->
-	<!-- Builds Cayenne documentation.              -->
+	<!-- Builds Cayenne documentation from Confluence -->
 	<!-- ========================================== -->
-	<target name="doc" depends="doc-img,grammars">
-		
-		<!-- Assemble project.xml -->
+	<target name="doc">
 		
-		<mkdir dir="${build.docs}"/>
-		
-		<loadfile property="project.toc" srcFile="${xdocs}/stylesheets/toc.xml"/>
-		<copy tofile="${build.docs}/project.xml"
-			file="${xdocs}/stylesheets/project.xml">
-			<filterset begintoken="&lt;!--@" endtoken="@--&gt;">
-				<filter token="TOC" value="${project.toc}"/>
-			</filterset>
-		</copy>
+		<!-- Compile Doc Builder -->
+		<compile-1_5 destdir="${core.build.tools}" srcref="srcpath-tools"
+					classpathref="classpath-tools"/>
 		
-		<!-- Build HTML documentation -->
-		<taskdef name="anakia" classname="org.apache.velocity.anakia.AnakiaTask">
-			<classpath refid="classpath-anakia"/>
+		<taskdef name="docgen" classname="org.objectstyle.cayenne.tools.ant.docgen.DocGenTask">
+			<classpath refid="classpath-built-tools"/>
 		</taskdef>
 		
-		<mkdir dir="${dist}/doc/dtd"/>
-		
-		<!-- 'projectFile' must be a relative reference... -->
-		<anakia basedir="${xdocs}" destdir="${dist}/doc" extension=".html"
-			style="cayenne.vsl" projectFile="../${build.suffix}/project.xml"
-			excludes="**/stylesheets/**" includes="**/*.xml"
-			lastModifiedCheck="true" templatePath="${xdocs}/stylesheets">
-		</anakia>
+		<!-- Clean the old docs, but not the SCM files -->
+		<delete>
+			<fileset dir="${cayenne.other}/wiki-docs" includes="**/*.html"/>
+		</delete>
+		
+		<!-- Build HTML documentation from Confluence -->
+		<docgen spaceKey="CAYDOC" docBase="${cayenne.other}/wiki-docs" startPage="Documentation"

+			username="${cayenne.confluence.user}" password="${cayenne.confluence.password}" />
+	</target>
+	
+	<!-- ========================================== -->
+	<!-- Installs Cayenne documentation -->
+	<!-- ========================================== -->
+	<target name="doc-install" depends="grammars">
+		<mkdir dir="${dist}/doc/"/>
 		
-		<!-- copy DTD's -->
+		<copy todir="${dist}/doc">
+			<fileset dir="${cayenne.other}/wiki-docs"/>
+		</copy>
+	
+		<!-- Copy other doc-related stuff -->
+		<mkdir dir="${dist}/doc/dtd"/>
 		<copy todir="${dist}/doc/dtd">
 			<fileset dir="${cayenne.java}/src/cayenne/dtd" includes="**/*.dtd"/>
 		</copy>
@@ -54,16 +52,6 @@
 		<copy todir="${dist}/doc/licenses">
 			<fileset dir="${license.dir}" includes="**/**"/>
 		</copy>
-		
-		<!-- Assemble License HTML page -->
-		<loadfile property="license.text" srcFile="${license.dir}/LICENSE.txt"/>
-		<move tofile="${build.docs}/license.html" file="${dist}/doc/license.html">
-			<filterset begintoken="&lt;!--@" endtoken="@--&gt;">
-				<filter token="LICENSE" value="${license.text}"/>
-			</filterset>
-		</move>
-		<move tofile="${dist}/doc/license.html"
-			file="${build.docs}/license.html"/>
 	</target>
 	
 	<!-- ========================================== -->
@@ -79,68 +67,4 @@
 			<property name="parser.doc.dir" value="${dist}/doc/grammar"/>
 		</ant>
 	</target>
-	
-	<!-- ========================================== -->
-	<!-- Copies documentation images in the target  -->
-	<!-- directory.                                 -->
-	<!-- ========================================== -->
-	<target name="doc-img">
-		<!-- copy images -->
-		<copy todir="${dist}/doc/images" filtering="no">
-			<fileset dir="${xdocs}/images">
-				<include name="**/*.gif"/>
-				<include name="**/*.jpeg"/>
-				<include name="**/*.png"/>
-				<include name="**/*.jpg"/>
-				<include name="**/*.css"/>
-			</fileset>
-		</copy>
-		
-		<!-- copy modeler buttons -->
-		<mkdir dir="${dist}/doc/images/modeler"/>
-		<copy todir="${dist}/doc/images/modeler" filtering="no" flatten="yes">
-			<fileset dir="${cayenne.java}/src/modeler/java">
-				<include name="**/*.gif"/>
-				<include name="**/*.jpeg"/>
-				<include name="**/*.png"/>
-				<include name="**/*.jpg"/>
-			</fileset>
-		</copy>
-	</target>
-	
-	<!-- ========================================== -->
-	<!-- Builds PDF documentation                   -->
-	<!-- ========================================== -->
-	<target name="pdf" depends="doc-img">
-		
-		<!-- Compile PDF Builder -->
-		<compile-1_5 destdir="${build.pdf}" srcref="srcpath-pdf-builder"
-			classpathref="classpath-tools"/>
-		
-		<java classname="org.objectstyle.cayenne.tools.pdf.PDFBuilder"
-			failonerror="true" fork="true" dir="${cayenne.other}">
-			<arg value="xdocs/modelerguide/"/>
-			<arg value="CayenneModeler Guide"/>
-			<arg value="${dist}/doc/modelerguide.pdf"/>
-			<classpath>
-				<path refid="classpath-tools"/>
-				<path location="${build.pdf}"/>
-			</classpath>
-		</java>
-		
-		<java classname="org.objectstyle.cayenne.tools.pdf.PDFBuilder"
-			failonerror="true" fork="true" dir="${cayenne.other}">
-			
-			<arg value="xdocs/userguide/"/>
-			<arg value="User Guide"/>
-			<arg value="${dist}/doc/userguide.pdf"/>
-			<classpath>
-				<path refid="classpath-tools"/>
-				<path location="${build.pdf}"/>
-			</classpath>
-		</java>
-		
-	</target>
 </project>
-
-

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/import/paths.xml
URL: http://svn.apache.org/viewcvs/incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/import/paths.xml?rev=405584&r1=405583&r2=405584&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/import/paths.xml (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-ant/ant/import/paths.xml Tue May  9 18:12:59
2006
@@ -106,7 +106,7 @@
 		<fileset dir="${cayenne.java}/lib" includes="javacc*.jar"/>
 	</path>
 	
-	<path id="classpath-anakia">
+	<path id="classpath-doc">
 		<!-- Exclude any XML parsers Ant might bundle...rely on JAXP instead -->
 		<fileset dir="${ant.home}/lib" includes="*.jar"
 			excludes="*xalan*,*xerces*,*xml-api*"/>
@@ -118,6 +118,12 @@
 	<path id="classpath-tools">
 		<fileset dir="${cayenne.other}/lib" includes="*.jar"/>
 		<path refid="classpath-cayenne-lib"/>
+	</path>
+	
+	<path id="classpath-built-tools">
+		<pathelement path="${build}/tools/classes"/>
+		<pathelement path="${cayenne.other}/src/tools/resources"/>
+		<path refid="classpath-tools"/>
 	</path>
 	
 	<path id="classpath-macosx">

Modified: incubator/cayenne/main/trunk/cayenne/cayenne-ant/build.xml
URL: http://svn.apache.org/viewcvs/incubator/cayenne/main/trunk/cayenne/cayenne-ant/build.xml?rev=405584&r1=405583&r2=405584&view=diff
==============================================================================
--- incubator/cayenne/main/trunk/cayenne/cayenne-ant/build.xml (original)
+++ incubator/cayenne/main/trunk/cayenne/cayenne-ant/build.xml Tue May  9 18:12:59 2006
@@ -42,7 +42,6 @@
 	   test-1_4     - runs JUnit tests
        testcoverage - runs JUnit test coverage analysis
        regression   - runs regression test application
-	   pdf          - builds PDF documentation
 	   mvn-install  - installs Cayenne in a local Maven2 repo (use "m2.repo" property to install
in a non-default location)
 	   mvn-bundle   - creates a Maven2 bundle in the format needed for Ibiblio upload
 
@@ -61,7 +60,9 @@
 		<ant antfile="ant/modeler.xml" target="dist-src" inheritrefs="true"/>
 		<ant antfile="ant/dvmodeler.xml" target="dist-src" inheritrefs="true"/>
 		<ant antfile="ant/tutorials.xml" target="dist-src" inheritrefs="true"/>
-		<ant antfile="ant/doc.xml" target="doc" inheritrefs="true"/>
+    	
+    		<!-- note that the docs have to be already prebuilt from Confluence and checked
in -->
+		<ant antfile="ant/doc.xml" target="doc-install" inheritrefs="true"/>
 		
 		<copy tofile="${dist}/RELEASE-NOTES.txt" file="${notes.dir}/RELEASE-NOTES-${project.version}.txt"/>
 		<copy tofile="${dist}/UPGRADE.txt" file="${notes.dir}/UPGRADE-${project.version}.txt"/>
@@ -170,6 +171,7 @@
     <!-- Builds Cayenne documentation.             -->
     <!-- ========================================== -->
     <target name="doc">
+		<ant antfile="ant/cayenne-java.xml" target="jar" inheritrefs="true"/>
         <ant antfile="ant/doc.xml" target="doc" inheritrefs="true"/>
         <ant antfile="ant/tutorials.xml" target="doc" inheritrefs="true"/>
     </target>
@@ -181,14 +183,6 @@
 	<target name="api">
 		<ant antfile="ant/cayenne-java.xml" target="api" inheritrefs="true"/>
 	</target>
-	
-	
-	<!-- ========================================== -->
-    <!-- Builds PDF documenatation.                 -->
-    <!-- ========================================== -->
-    <target name="pdf" description="builds PDF documentation.">
-		<ant antfile="ant/doc.xml" target="pdf" inheritrefs="true"/>
-    </target>
 	
 	<!-- ========================================== -->
     <!-- Installs Cayenne in the local M2 rep       -->



Mime
View raw message