db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From scott hutinger <s-hutin...@wiu.edu>
Subject Re: [jira] Created: (DERBY-221) User documentation should include a timestamp and/or svn revision number
Date Wed, 13 Apr 2005 19:32:44 GMT
Cool!

I had to change 1 thing, and add 1 item and the date works, although it 
should be modified a bit.
I still agree with Andrew that the SVN revision number should be included:

--- temp.xsl    2005-04-13 14:30:48.736362255 -0500
+++ dita2fo-shell.xsl   2005-04-13 14:27:06.640693035 -0500
@@ -1,4 +1,3 @@
-
 <?xml version="1.0" encoding="UTF-8" ?>
 <!-- (c) Copyright IBM Corp. 2004, 2005 All Rights Reserved. -->

@@ -35,7 +34,9 @@
 <xsl:stylesheet version="1.0"
                 xmlns:fo="http://www.w3.org/1999/XSL/Format"
                 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
-                xmlns:fox="http://xml.apache.org/fop/extensions">
+                xmlns:fox="http://xml.apache.org/fop/extensions"
+                xmlns:java="http://xml.apache.org/xslt/java"
+>
   <!-- stylesheet imports -->
   <xsl:import href="xslfo/topic2foImpl.xsl"/>
   <xsl:import href="xslfo/domains2fo.xsl"/>
@@ -176,10 +177,11 @@
         </fo:block>
       </fo:block>

-
+
  <!-- set the brief timestamp -->
 <fo:block margin-top="3pc" text-align="right" font-size="8pt" 
line-height="normal">
           Derby Document build: 2005-04-12T11:30PST : 12 April 2005
+  <xsl:call-template name="TodaysDate"/>
 </fo:block>

 <!-- <xsl:call-template name="TodaysDate"/> (Currently not working...) -->
@@ -225,13 +227,13 @@
     </fo:page-sequence>
   </xsl:template>

-<!-- Timestamp template that currently causes errors
-<xsl:template match="TodaysDate">
+<!-- Timestamp template that currently causes errors -->
+<xsl:template name="TodaysDate">
 <fo:block>
     <xsl:value-of select="java:format(java:java.text.SimpleDateFormat.new
 ('MMMM d, yyyy, h:mm:ss a (zz)'), java:java.util.Date.new())"/>
  </fo:block>
- </xsl:template>-->
+ </xsl:template>


 <!-- Jeff is adding this to replace the piece below -->
@@ -448,4 +450,3 @@
     </xsl:for-each>
   </xsl:template>
 </xsl:stylesheet>
-




Jeff Levitt wrote:

>The following code is currently commented out but
>included in the mods we have made to the
>dita2fo-shell.xsl file in the DITA Toolkit:
>
><!-- Timestamp template that currently causes errors
><xsl:template match="TodaysDate">
><fo:block>
>    <xsl:value-of
>select="java:format(java:java.text.SimpleDateFormat.new
>('MMMM d, yyyy, h:mm:ss a (zz)'),
>java:java.util.Date.new())"/>
> </fo:block>
> </xsl:template> -->
>
>
>
>This is called on the cover page (but also commented
>out):
><!-- <xsl:call-template name="TodaysDate"/> (Currently
>not working...) -->
>
>
>
>This method causes errors that fail the build, so
>after commenting them out for now, I added this less
>dynamic method to temporarily add timestamps to the
>cover page:
><!-- set the brief timestamp -->
><fo:block margin-top="3pc" text-align="right"
>font-size="8pt" line-height="normal">
>          Derby Document build: 2005-04-12T11:30PST :
>12 April 2005
></fo:block> 
>
>
>
>Obviously, this is not desirable as it means you have
>to hard code a new timestamp before creating output
>each time.
>
>If anyone can get the former method working, we'll
>have our timestamp!
>
>
>
>
>--- "Samuel Andrew McIntyre (JIRA)"
><derby-dev@db.apache.org> wrote:
>  
>
>>User documentation should include a timestamp and/or
>>svn revision number
>>
>>    
>>
>------------------------------------------------------------------------
>  
>
>>         Key: DERBY-221
>>         URL:
>>http://issues.apache.org/jira/browse/DERBY-221
>>     Project: Derby
>>        Type: Improvement
>>  Components: Documentation  
>>    Versions: 10.1.0.0    
>>    Reporter: Samuel Andrew McIntyre
>>    Priority: Minor
>>     Fix For: 10.1.0.0
>>
>>
>>In order to easily identify when a set of
>>documentation was generated, it would be useful to
>>add a timestamp, and possibly the svn revision at
>>which the documentation was generated, to the
>>output. One approach would be to replace a token in
>>either the input files or final output with the
>>appropriate information using Ant. This may not work
>>for PDFs, in which case the timestamp may need to be
>>inserted at the intermediate XSL-FO stage.
>>
>>-- 
>>This message is automatically generated by JIRA.
>>-
>>If you think it was sent incorrectly contact one of
>>the administrators:
>>  
>>
>>    
>>
>http://issues.apache.org/jira/secure/Administrators.jspa
>  
>
>>-
>>If you want more information on JIRA, or have a bug
>>to report see:
>>   http://www.atlassian.com/software/jira
>>
>>
>>    
>>
>
>  
>


Mime
View raw message