Purpose
To perform XSLT from the command line.
What you need
Instructions
1. Unpack Xalan-J
2. Find your input XML and XSL files
3. Run!
Too simple? I don't know. I had to look around for a long time before I figured out that it's so simple.
Sample Command Script
The following are commands for downloading Xalan from a mirror, unpacking it, and using it from the command line on included sample files.
| cd ~ |
| curl -L -O http://www.devlib.org/apache/xml/xalan-j/xalan-j_2_7_0-bin.tar.gz |
| gunzip xalan-j_2_7_0-bin.tar.gz |
| tar xf xalan-j_2_7_0-bin.tar |
| java -cp ~/xalan-j_2_7_0 org.apache.xalan.xslt.Process -in ~/xalan-j_2_7_0/samples/SimpleTransform/birds.xml -xsl ~/xalan-j_2_7_0/samples/SimpleTransform/birds.xsl -out ~/birds.out |
| cat ~/birds.out |
All you need to do is use your own files for the -in and -xsl arguments.
Comments (0)
You don't have permission to comment on this page.