tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From funk...@apache.org
Subject svn commit: r601180 - in /tomcat/trunk: build.xml webapps/docs/build.xml webapps/docs/tomcat-docs.xsl
Date Wed, 05 Dec 2007 01:08:57 GMT
Author: funkman
Date: Tue Dec  4 17:08:54 2007
New Revision: 601180

URL: http://svn.apache.org/viewvc?rev=601180&view=rev
Log:
http://code.google.com/p/google-highly-open-participation-asf/issues/detail?id=23

Printer friendlize the docs 

Also discovered webapps/docs/build.xml is no longer used from the 
main build.xml. Can that be chucked?


Modified:
    tomcat/trunk/build.xml
    tomcat/trunk/webapps/docs/build.xml
    tomcat/trunk/webapps/docs/tomcat-docs.xsl

Modified: tomcat/trunk/build.xml
URL: http://svn.apache.org/viewvc/tomcat/trunk/build.xml?rev=601180&r1=601179&r2=601180&view=diff
==============================================================================
--- tomcat/trunk/build.xml (original)
+++ tomcat/trunk/build.xml Tue Dec  4 17:08:54 2007
@@ -90,7 +90,7 @@
     <delete dir="${tomcat.build}/temp" />
     <delete dir="${tomcat.build}/work" />
 
-  	<mkdir dir="${tomcat.build}"/>
+    <mkdir dir="${tomcat.build}"/>
     <mkdir dir="${tomcat.build}/bin"/>
     <mkdir dir="${tomcat.build}/conf"/>
     <mkdir dir="${tomcat.build}/lib"/>
@@ -115,8 +115,8 @@
     </javac>
     <tstamp>
       <format property="TODAY" pattern="MMM d yyyy" locale="en"/>
-      <format property="TSTAMP" pattern="hh:mm:ss"/>        
-    </tstamp>    
+      <format property="TSTAMP" pattern="hh:mm:ss"/>
+    </tstamp>
     <!-- Copy static resource files -->
     <filter token="VERSION" value="${version}"/>
     <filter token="VERSION_NUMBER" value="${version.number}"/>
@@ -184,7 +184,7 @@
     </jar>
 
     <!-- Bootstrap JAR File -->
-    <jar jarfile="${bootstrap.jar}" 
+    <jar jarfile="${bootstrap.jar}"
         manifest="res/bootstrap.jar.manifest">
       <fileset dir="${tomcat.classes}">
         <include name="org/apache/catalina/startup/Bootstrap.class" />
@@ -233,7 +233,7 @@
         <exclude name="org/apache/naming/factory/webservices/**" />
       </fileset>
     </jar>
-    
+
     <!-- Catalina GroupCom/Tribes JAR File -->
     <jar jarfile="${catalina-tribes.jar}">
       <fileset dir="${tomcat.classes}">
@@ -341,15 +341,15 @@
       </fileset>
     </copy>
     <filter token="VERSION" value="${version}"/>
-    <copy tofile="${tomcat.build}/webapps/docs/RELEASE-NOTES.txt" file="RELEASE-NOTES"

+    <copy tofile="${tomcat.build}/webapps/docs/RELEASE-NOTES.txt" file="RELEASE-NOTES"
           filtering="true" />
 
     <copy   tofile="${tomcat.build}/webapps/docs/appdev/sample/build.xml"
               file="webapps/docs/appdev/build.xml.txt"/>
-  	
-  	<mkdir dir="${tomcat.build}/webapps/docs/funcspecs" />
-  	
-  	<!-- XSL processing -->
+
+    <mkdir dir="${tomcat.build}/webapps/docs/funcspecs" />
+
+    <!-- XSL processing -->
     <style basedir="webapps/docs"
            destdir="${tomcat.build}/webapps/docs"
          extension=".html"
@@ -390,7 +390,7 @@
           includes="*.xml">
       <param name="relative-path" expression=".."/>
     </style>
-    
+
     <style basedir="webapps/docs/tribes"
                destdir="${tomcat.build}/webapps/docs/tribes"
              extension=".html"
@@ -399,72 +399,6 @@
               includes="*.xml">
           <param name="relative-path" expression=".."/>
     </style>
-
-  	<!-- Print friendly version -->
-  	<mkdir dir="${tomcat.build}/webapps/docs/printer" />
-    <copy todir="${tomcat.build}/webapps/docs/printer">
-      <fileset dir=".">
-        <include name="BUILDING.txt"/>
-        <include name="NOTICE"/>
-        <include name="RUNNING.txt"/>
-      </fileset>
-    </copy>
-  	<mkdir dir="${tomcat.build}/webapps/docs/appdev/printer" />
-    <copy todir="${tomcat.build}/webapps/docs/appdev/printer">
-        <fileset dir="webapps">
-          <include name="docs/appdev/*.txt"/>
-        </fileset>
-    </copy>
-  	<mkdir dir="${tomcat.build}/webapps/docs/funcspecs/printer" />
-    <mkdir dir="${tomcat.build}/webapps/docs/architecture/printer"/>
-    <mkdir dir="${tomcat.build}/webapps/docs/config/printer"/>
-
-  	<style basedir="webapps/docs"
-           destdir="${tomcat.build}/webapps/docs/printer"
-         extension=".html"
-             style="webapps/docs/tomcat-docs.xsl"
-          excludes="build.xml project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="./.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-    <style basedir="webapps/docs/appdev"
-           destdir="${tomcat.build}/webapps/docs/appdev/printer"
-         extension=".html"
-             style="webapps/docs/tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-    <style basedir="webapps/docs/funcspecs"
-           destdir="${tomcat.build}/webapps/docs/funcspecs/printer"
-         extension=".html"
-             style="webapps/docs/tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-    <style basedir="webapps/docs/config"
-           destdir="${tomcat.build}/webapps/docs/config/printer"
-         extension=".html"
-             style="webapps/docs/tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-    <style basedir="webapps/docs/architecture"
-           destdir="${tomcat.build}/webapps/docs/architecture/printer"
-         extension=".html"
-             style="webapps/docs/tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-
   </target>
 
   <target name="deploy" depends="build-only,build-docs">
@@ -475,14 +409,14 @@
     <copy todir="${tomcat.build}/bin" file="${commons-daemon.jar}" />
     <copy todir="${tomcat.build}/bin" file="${commons-daemon.jsvc.tar.gz}" />
 
-  	<!-- Copy scripts -->
+    <!-- Copy scripts -->
     <copy todir="${tomcat.build}/bin">
       <fileset dir="bin">
          <exclude name="**/*.launch"/>
       </fileset>
     </copy>
 
-  	<!-- Copy static resource files -->
+    <!-- Copy static resource files -->
     <copy todir="${tomcat.build}/conf">
       <fileset dir="conf">
         <include name="**/*.policy"/>
@@ -502,29 +436,29 @@
     </copy>
 
     <filter token="VERSION" value="${version}"/>
-    <copy tofile="${tomcat.build}/webapps/ROOT/RELEASE-NOTES.txt" file="RELEASE-NOTES"

+    <copy tofile="${tomcat.build}/webapps/ROOT/RELEASE-NOTES.txt" file="RELEASE-NOTES"
           filtering="true" />
 
     <!-- Build classes for examples webapp -->
-    <javac   srcdir="webapps/examples/WEB-INF/classes" 
+    <javac   srcdir="webapps/examples/WEB-INF/classes"
              destdir="${tomcat.build}/webapps/examples/WEB-INF/classes"
              debug="${compile.debug}" deprecation="${compile.deprecation}"
              optimize="${compile.optimize}"
-    	     classpath="${tomcat.classes}"
+             classpath="${tomcat.classes}"
              excludes="**/CVS/**,**/.svn/**">
     </javac>
-  	
-    <javac   srcdir="webapps/examples/jsp/plugin/applet" 
+
+    <javac   srcdir="webapps/examples/jsp/plugin/applet"
              destdir="${tomcat.build}/webapps/examples/jsp/plugin/applet"
              debug="${compile.debug}" deprecation="${compile.deprecation}"
              optimize="${compile.optimize}"
-    	     classpath="$tomcat.lcasses}"
+             classpath="$tomcat.lcasses}"
              excludes="**/CVS/**,**/.svn/**">
     </javac>
 
-  	<!-- Add sources for examples -->
-	<taskdef    name="txt2html"
-		   classname="org.apache.tomcat.buildutil.Txt2Html"
+    <!-- Add sources for examples -->
+    <taskdef    name="txt2html"
+           classname="org.apache.tomcat.buildutil.Txt2Html"
            classpath="${tomcat.classes}" />
     <txt2html todir="${tomcat.build}/webapps/examples/jsp/jsp2/simpletag">
       <fileset dir="webapps/examples/WEB-INF/classes/jsp2/examples">
@@ -600,17 +534,17 @@
       </fileset>
     </txt2html>
 
-  	<copy file="${tomcat-dbcp.jar}" todir="${tomcat.build}/lib" />
+    <copy file="${tomcat-dbcp.jar}" todir="${tomcat.build}/lib" />
     <copy file="${jasper-jdt.jar}" todir="${tomcat.build}/lib" />
 
   </target>
-	
+
   <target name="clean-depend"
-	     description="Clean depend src components">
-	 <delete dir="${tomcat-dbcp.home}"/>    
-	 <delete dir="${jasper-jdt.home}"/>
+         description="Clean depend src components">
+     <delete dir="${tomcat-dbcp.home}"/>
+     <delete dir="${jasper-jdt.home}"/>
   </target>
-	
+
   <target name="clean">
     <delete dir="${tomcat.classes}" />
     <delete dir="${tomcat.build}" />
@@ -707,7 +641,7 @@
 
   <target name="build-tomcat-dbcp">
     <copy todir="${tomcat-dbcp.home}">
-    <!-- 
+    <!--
       <fileset dir="${commons-collections.home}" >
         <include name="**/collections/CursorableLinkedList.java" />
         <include name="**/collections/KeyValue.java" />
@@ -724,7 +658,7 @@
         <exclude name="**/test/**" />
       </fileset>
     </copy>
-  	<!--
+    <!--
     <replace dir="${tomcat-dbcp.home}/src/java/org/apache/commons">
       <replacefilter token="return UnmodifiableList.decorate(l);"
             value="return l;" />

Modified: tomcat/trunk/webapps/docs/build.xml
URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/build.xml?rev=601180&r1=601179&r2=601180&view=diff
==============================================================================
--- tomcat/trunk/webapps/docs/build.xml (original)
+++ tomcat/trunk/webapps/docs/build.xml Tue Dec  4 17:08:54 2007
@@ -18,240 +18,12 @@
 <project name="tomcat-docs" default="build-main" basedir=".">
 
 
-  <!-- ===================== Initialize Property Values =================== -->
+  <target name="build-main">
+   <echo>
 
-  <!-- See "build.properties.sample" in the top level directory for all     -->
-  <!-- property values you must customize for successful building!!!        -->
-  <property file="build.properties"/>
-  <property file="../build.properties"/>
-  <property file="../../build.properties"/>
-  <property file="${user.home}/build.properties"/>
-
-  <property name="build.compiler"  value="modern"/>
-  <property name="webapps.build"   value="../build"/>
-  <property name="webapps.dist"    value="../dist"/>
-  <property name="webapp.name"     value="tomcat-docs"/>
-
-
-  <!-- =================== BUILD: Create Directories ====================== -->
-  <target name="build-prepare">
-    <mkdir dir="${webapps.build}"/>
-    <mkdir dir="${webapps.build}/${webapp.name}"/>
-  </target>
-
-
-  <!-- ================ BUILD: Copy Static Files ========================== -->
-  <target name="build-static" depends="build-prepare">
-
-    <!-- Top Level Static Files -->
-    <copy    todir="${webapps.build}/${webapp.name}">
-      <fileset dir="../..">
-        <include name="BUILDING.txt"/>
-        <include name="README.txt"/>
-        <include name="RUNNING.txt"/>
-      </fileset>
-    </copy>
-    <copy    todir="${webapps.build}/${webapp.name}">
-      <fileset dir="." includes="**/*.html"/>
-    </copy>
-
-    <!-- WEB-INF Static Files -->
-    <copy    todir="${webapps.build}/${webapp.name}/WEB-INF">
-      <fileset dir="WEB-INF"/>
-    </copy>
-
-    <!-- Application Developer's Guide Examples -->
-    <copy    todir="${webapps.build}/${webapp.name}/appdev">
-      <fileset dir="appdev" includes="*.txt"/>
-    </copy>
-
-    <!-- This copy includes a binary file (sample.war) so it should not have a filter
token -->
-    <!-- See Bugzilla 36318: http://issues.apache.org/bugzilla/show_bug.cgi?id=36318 -->
-    <copy    todir="${webapps.build}/${webapp.name}/appdev/sample">
-      <fileset dir="appdev/sample"/>
-    </copy>
-
-    <copy   tofile="${webapps.build}/${webapp.name}/appdev/sample/build.xml"
-              file="appdev/build.xml.txt"/>
-
-    <!-- Catalina Functional Specifications -->
-    <mkdir     dir="${webapps.build}/${webapp.name}/catalina/funcspecs"/>
-
-    <!-- Architecture -->
-    <copy    todir="${webapps.build}/${webapp.name}/architecture">
-      <fileset dir="architecture" excludes="*.xml"/>
-    </copy>
-
-    <!-- Images Subdirectory -->
-    <mkdir     dir="${webapps.build}/${webapp.name}/images"/>
-    <copy    todir="${webapps.build}/${webapp.name}/images">
-      <fileset dir="images"/>
-    </copy>
-
-    <mkdir     dir="${webapps.build}/${webapp.name}/printer"/>
-    <!-- Top Level Static Files -->
-    <copy    todir="${webapps.build}/${webapp.name}/printer">
-      <fileset dir="../..">
-        <include name="BUILDING.txt"/>
-        <include name="README.txt"/>
-        <include name="RUNNING.txt"/>
-      </fileset>
-    </copy>
-    <style basedir="."
-           destdir="${webapps.build}/${webapp.name}/printer"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="build.xml project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="./.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-
-    <!-- WEB-INF Subdirectory -->
-    <mkdir     dir="${webapps.build}/${webapp.name}/WEB-INF"/>
-    <copy    todir="${webapps.build}/${webapp.name}/WEB-INF">
-      <fileset dir="WEB-INF"/>
-    </copy>
-
-  </target>
-
-
-  <!-- ================= BUILD: XML-HTML Generation ======================= -->
-  <target name="build-main" depends="build-static">
-
-    <!-- Top Level Directory -->
-    <style basedir="."
-           destdir="${webapps.build}/${webapp.name}"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="build.xml project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="."/>
-    </style>
-
-    <!-- Application Developer's Guide -->
-    <style basedir="appdev"
-           destdir="${webapps.build}/${webapp.name}/appdev"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression=".."/>
-    </style>
-    <mkdir     dir="${webapps.build}/${webapp.name}/appdev/printer"/>
-    <!-- Application Developer's Guide Examples -->
-    <copy    todir="${webapps.build}/${webapp.name}/appdev/printer">
-      <fileset dir="appdev" includes="*.txt"/>
-    </copy>
-    <style basedir="appdev"
-           destdir="${webapps.build}/${webapp.name}/appdev/printer"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-
-    <!-- Catalina Functional Specifications -->
-    <mkdir     dir="${webapps.build}/${webapp.name}/catalina"/>
-    <mkdir     dir="${webapps.build}/${webapp.name}/catalina/funcspecs"/>
-    <style basedir="funcspecs"
-           destdir="${webapps.build}/${webapp.name}/catalina/funcspecs"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-    </style>
-    <mkdir     dir="${webapps.build}/${webapp.name}/catalina/funcspecs/printer"/>
-    <style basedir="funcspecs"
-           destdir="${webapps.build}/${webapp.name}/catalina/funcspecs/printer"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-
-    <!-- Server Configuration Reference -->
-    <style basedir="config"
-           destdir="${webapps.build}/${webapp.name}/config"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression=".."/>
-    </style>
-    <mkdir     dir="${webapps.build}/${webapp.name}/config/printer"/>
-    <style basedir="config"
-           destdir="${webapps.build}/${webapp.name}/config/printer"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
-
-    <!-- Server Architecture -->
-    <style basedir="architecture"
-           destdir="${webapps.build}/${webapp.name}/architecture"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression=".."/>
-    </style>
-    <mkdir     dir="${webapps.build}/${webapp.name}/architecture/printer"/>
-    <style basedir="architecture"
-           destdir="${webapps.build}/${webapp.name}/architecture/printer"
-         extension=".html"
-             style="tomcat-docs.xsl"
-          excludes="project.xml"
-          includes="*.xml">
-      <param name="relative-path" expression="../.."/>
-      <param name="project-menu" expression="nomenu"/>
-    </style>
+I am no longer used and I need deleted !!!
 
+   </echo>
   </target>
-
-
-  <!-- ==================== BUILD: Rebuild Everything ===================== -->
-  <target name="all" depends="build-clean,build-main"
-   description="Clean and build documentation webapp"/>
-
-
-  <!-- ======================= BUILD: Clean Directory ===================== -->
-  <target name="build-clean">
-    <delete dir="${webapps.build}/${webapp.name}"/>
-  </target>
-
-
-  <!-- ======================= DIST: Create Directories =================== -->
-  <target name="dist-prepare">
-    <mkdir dir="${webapps.dist}"/>
-  </target>
-
-
-  <!-- ======================= DIST: Create Distribution Files ============ -->
-  <target name="dist" depends="build-main,dist-prepare"
-   description="Create documentation webapp binary distribution">
-      <jar   jarfile="${webapps.dist}/${webapp.name}.war"
-             basedir="${webapps.build}/${webapp.name}" includes="**"/>
-  </target>
-
-
-  <!-- ======================= DIST: Clean Directory ====================== -->
-  <target name="dist-clean">
-    <delete dir="${webapps.dist}/${webapp.name}"/>
-  </target>
-
-
-  <!-- ====================== Convenient Synonyms ========================= -->
-  <target name="clean" depends="build-clean,dist-clean"
-   description="Clean build and dist directories"/>
-
 
 </project>

Modified: tomcat/trunk/webapps/docs/tomcat-docs.xsl
URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/tomcat-docs.xsl?rev=601180&r1=601179&r2=601180&view=diff
==============================================================================
--- tomcat/trunk/webapps/docs/tomcat-docs.xsl (original)
+++ tomcat/trunk/webapps/docs/tomcat-docs.xsl Tue Dec  4 17:08:54 2007
@@ -71,6 +71,10 @@
       <meta name="author" value="{$name}"/>
       <meta name="email" value="{$email}"/>
     </xsl:for-each>
+		<style type="text/css" media="print">
+			.noPrint {display: none;}
+			td#mainBody {width: 100%;}
+		</style>
     </head>
 
     <body bgcolor="{$body-bg}" text="{$body-fg}" link="{$body-link}"
@@ -126,47 +130,15 @@
 
       <tr>
 
-        <!-- Don't generate a menu if styling printer friendly docs -->
-        <xsl:if test="$project-menu = 'menu'">
-          <xsl:comment>LEFT SIDE NAVIGATION</xsl:comment>
-          <td width="20%" valign="top" nowrap="true">
-            <xsl:apply-templates select="project/body/menu"/>
-          </td>
-        </xsl:if>
+        <xsl:comment>LEFT SIDE NAVIGATION</xsl:comment>
+        <td width="20%" valign="top" nowrap="true" class="noPrint">
+          <xsl:apply-templates select="project/body/menu"/>
+        </td>
 
         <xsl:comment>RIGHT SIDE MAIN BODY</xsl:comment>
-        <td width="80%" valign="top" align="left">
-          <table border="0" width="100%" cellspacing="4">
-            <tr>
-              <td align="left" valign="top">
-                <h1><xsl:value-of select="project/title"/></h1>
-                <h2><xsl:value-of select="properties/title"/></h2>
-              </td>
-              <td align="right" valign="top" nowrap="true">
-                <!-- Add the printer friendly link for docs with a menu -->
-                <xsl:if test="$project-menu = 'menu'">
-                  <xsl:variable name="src">
-                    <xsl:value-of select="$relative-path"/><xsl:value-of select="$printer-logo"/>
-                  </xsl:variable>
-                  <xsl:variable name="url">
-                    <xsl:value-of select="/document/@url"/>
-                  </xsl:variable>
-                  <small>
-                    <a href="printer/{$url}">
-                      <img src="{$src}" border="0" alt="Printer Friendly Version"/>
-                      <br />print-friendly<br />version
-                    </a>
-                  </small>
-                </xsl:if>
-                <xsl:if test="$project-menu != 'menu'">
-                  <xsl:variable name="void">
-                    <xsl:value-of select="$relative-path"/><xsl:value-of select="$void-image"/>
-                    </xsl:variable>
-                  <img src="{$void}" width="1" height="1" vspace="0" hspace="0" border="0"/>
-                </xsl:if>
-              </td>
-            </tr>
-          </table>
+        <td width="80%" valign="top" align="left" id="mainBody">
+          <h1><xsl:value-of select="project/title"/></h1>
+          <h2><xsl:value-of select="properties/title"/></h2>
           <xsl:apply-templates select="body/section"/>
         </td>
 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message