We use Apache Ant to control builds.  It is possible to use it directly to 
invoke a transform (using the XSLT task).  By default, Xalan is bound as the 
XSLT transform engine, but it can be replaced with Saxon fairly easily.  A big 
advantage it has is working cross-platform, which is important because we have 
users on Linux and HP-UX in addition to Windows.  You can also execute command 
on the command line using the exec task. 

Everything is based on the idea of targets that perform specific function and 
are built of tasks.  It is pretty straightforward for simple things like a 
single transform invocation, but provides enough sophistication to handle 
sequencing processing transforms and packaging up results into ZIP files with 
the HTML and the image files combined into a destination directory and then 
collected into a ZIP file.

Another thing useful is it is XML, so the same editors used for content can be 
used to modify the file that controls the build process.  We also have some 
build processes for advanced functions that create a new build file on the fly 
using XSLT and then transfer control to it for a part of the build.  This makes 
it very powerful.

For people who don't like the command line, we provide simple .bat files that 
invoke specific targets in the build (targets are what get executed in Ant) so 
that the user can just double-click on build.bat and build-to-validate.bat 
without having to go to the command line on Windows.  Most UNIX users don't 
feel the need for shell scripts to launch the Ant builds and prefer to do so 
from the command line to have the added flexibility that the command line gives 
of defining some parameters to the build when it is invoked.

The manual for Apache is available online at 
http://ant.apache.org/manual/index.html

In the left-hand navigation, click on "Ant Tasks," then "Core Tasks" and 
"XSLT/Style" will be at the bottom of the navigation column.

Larry Rowland

-----Original Message-----
From: Karen Schneider [mailto:[email protected]] 
Sent: Saturday, May 16, 2009 10:11 AM
To: [email protected]
Subject: [docbook-apps] xlstproc questions (was: CSS begging)

Johann (and Dave and Fabrice), thank you! I am now able to demo "and
this is what it looks like, styled" -- which is very useful. I will
put my slides on Slideshare early next week.

I told myself that would be my last question before Wednesday's talk
but the mention of xsltproc raised questions about its use as well. (I
am using both free tools such as xsltproc and xmlmind side-by-side
with oXygen so I can demonstrate some choice in tool selection. Most
but not all people at this demo will be working in Windows and like
me, will start with free tools.)

For Windows users, is it common usage to create a batch file for
xsltproc that substitutes as a kind of Makefile to document processes?

Also, I had trouble with DOS path names in my xsltproc commands and
the Windows (really, DOS...) guidance for xsltproc I found on the web
seemed vague.

This:

C:\XMLTOOLS>xsltproc --stringparam base.dir c:\XMLTOOLS\test7-
--stringparam html.stylesheet boetest.css
c:\xmltools\docbook-xsl\xhtml\chunk.xsl
h:\docsrepo\TechRef\JSONGrammar.xml

produced a strange long filename... if I left off the path that didn't
happen. If I changed the path, say, to h:\test\results\test8- the file
stayed in teh directory with another strange long filename, like the
other, concatenated from the path.Obviously, there's a right way to
express the path and that isn't it.

Finally, if anyone has really precise instructions for permanently
setting the path for xsltproc, that would be great. Most directions on
the Web are vague (try googling: your computer's environment variable
xsltproc) and I had to ask a couple of friends who like me hadn't done
anything like this in, oh... a decade.

-- 
-- 
| Karen G. Schneider
| Community Librarian
| Equinox Software Inc. "The Evergreen Experts"
| Toll-free: 1.877.Open.ILS (1.877.673.6457) x712
| [email protected]
| Web: http://www.esilibrary.com
| Be a part of the Evergreen International Conference, May 20-22, 2009!
| http://www.lyrasis.org/evergreen

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to