Skip to content

Commit 90c4cbe

Browse files
committed
Merge branch 'develop'
2 parents ec41097 + 2073c6a commit 90c4cbe

File tree

322 files changed

+32294
-2167
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

322 files changed

+32294
-2167
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,6 @@ hs_err_pid*
1313

1414
*/generationManifests*
1515
*generation-manifest*
16+
doctypes/oasis/2.0/rng-media
17+
!lib/*.jar
18+
.ant-targets-build-plugins.xml

README.md

Lines changed: 28 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
1-
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<title>OASIS TC Open Repository: dita-rng-converter</title>
5+
</head>
6+
<body>
27
<div>
38
<h1>README</h1>
49

@@ -20,7 +25,14 @@
2025

2126
<p>Statement of Purpose for this OASIS TC Open Repository (dita-rng-converter) as <a href="https://lists.oasis-open.org/archives/dita/201601/msg00040.html">proposed</a> and <a href="https://www.oasis-open.org/committees/download.php/57596/minutes20160223.txt">approved</a> by the TC:</p>
2227

23-
<p>The repository manages the source code and supporting documentation for the RELAX NG-to-DTD and RELAX NG-to-XSD (and any other RNG-to-X transforms that might be developed, such as RELAX NG-to-EDD or RELAX NG-to-Schematron) transforms developed originally for use by the DITA TC in producing the <a href="http://docs.oasis-open.org/dita/dita/v1.3/">DITA 1.3</a> DTDs and XSDs from the normative RELAX NG versions of the DITA 1.3 grammar. The converter is intended to make it easy for any DITA user to develop and maintain their own document type shells, constraint modules, and vocabulary modules using RELAX NG, which has proven to be much easier to use than DTD or XSD.</p>
28+
<p>The repository manages the source code and supporting documentation for the RELAX NG-to-DTD and
29+
RELAX NG-to-XSD (and any other RNG-to-X transforms that might be developed, such as RELAX
30+
NG-to-EDD or RELAX NG-to-Schematron) transforms developed originally for use by the DITA
31+
TC in producing the <a href="http://docs.oasis-open.org/dita/dita/v1.3/">DITA 1.3</a> and
32+
DITA 2.x DTDs and XSDs from the normative RELAX NG versions of the DITA 1.3 and DITA 2.x
33+
grammars. The converter is intended to make it easy for any DITA user to develop and
34+
maintain their own document type shells, constraint modules, and vocabulary modules using
35+
RELAX NG, which has proven to be much easier to use than DTD or XSD.</p>
2436

2537
</div>
2638

@@ -29,14 +41,20 @@
2941
<div><h3>Tool Overview</h3>
3042
<p>
3143
This project provides the following transforms from RNG grammars that follow the coding conventions used by the DITA Technical Committee for the TC-defined modules and shells:
32-
<ul>
33-
<li>RNG-to-DTD: Generates conforming DTD-syntax document type shells and modules</li>
34-
<li>RNG-to-XSD: Generates conforming XSD-syntax document type shells and modules</li>
44+
</p><ul>
45+
<li>RNG-to-DTD: Generates both DTD-syntax document type shells and modules as well as single-file
46+
("monolithic") DTDs.</li>
47+
<li>RNG-to-XSD: Generates both modular (DITA 1.x-style) XSD-syntax document type shells and modules
48+
that use the XSD redefine feature (within limits on the ability to generate modular
49+
constrained XSDs) as well as "monolithic" single-file XSDs that do not use
50+
redefine.</li>
3551
<li>XML entity resolution catalog generator: Generates XML entity resolution catalogs for the RNG, DTD, and XSD modules processed or generated.</li>
3652
</ul>
3753
<p>The transforms are implemented as XSLT transforms and run through an Ant script. See the project documentation for details.</p>
38-
<p>The transforms can be run standalone or through an Open Toolkit plugin. The transforms have no dependency on the DITA Open Toolkit itself.</p>
39-
<p>You can use these transforms to generate both DITA 1.2 and DITA 1.3 shells and modules: RNG versions of the DITA 1.2 shells and vocabulary are included in the project (as developed by the DITA Technical Committee).</p>
54+
<p>The transforms can be run standalone or through an Open Toolkit plug-in. The transforms have no
55+
dependency on DITA Open Toolkit itself.</p>
56+
<p>You can use these transforms to generate shells and modules for all DITA versions through
57+
2.0.</p>
4058
<p><b>NOTE:</b> At some point the OASIS-defined grammars will be removed from this project and you'll need to get the latest DITA Open Toolkit
4159
distribution in order to minimize the number of copies of the OASIS-provided grammars.</p>
4260
</div>
@@ -45,15 +63,15 @@ distribution in order to minimize the number of copies of the OASIS-provided gra
4563
<p>The code as added 24 March 2016 is still under development and requires more work to make it
4664
ready for general use. The latest code is on the develop branch.</p>
4765
<p>The current development plan is:
48-
<ol>
66+
</p><ol>
4967
<li>Fix bugs related to infinite looping of code when generating shells, as reported by
5068
Toshihiko Makita on the DITA Community version of the repo (https://github.com/dita-community/dita-rng-converter/issues/2)</li>
5169
<li>Refine the Ant scripts to ensure that all parameters are appropriate and working.</li>
5270
<li>Finish documentation.</li>
5371
</ol>
5472
<p>Schedule: Goal is to complete these actions by the end of December 2016 or as early in 2017 as possible.</p>
5573
<p>Additional implementation goals include:
56-
<ul>
74+
</p><ul>
5775
<li>Provide a simple interactive tool for creating new document type shells and generating DTD and XSD from them.</li>
5876
<li>Implement a FrameMaker EDD generation process to make it easier to use local shells, specializations, and
5977
constraints with FrameMaker.</li>
@@ -95,3 +113,4 @@ constraints with FrameMaker.</li>
95113
<p>Questions or comments about this TC Open Repository's activities should be composed as GitHub issues or comments. If use of an issue/comment is not possible or appropriate, questions may be directed by email to the Maintainer(s) <a href="#currentMaintainers">listed above</a>. Please send general questions about TC Open Repository participation to OASIS Staff at <a href="mailto:[email protected]">[email protected]</a> and any specific CLA-related questions to <a href="mailto:[email protected]">[email protected]</a>.</p>
96114

97115
</div></div>
116+
</body></html>

build-test.xml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,6 @@
1717

1818
<import file="build.xml"/>
1919

20-
<target name="generate-all"
21-
description="Generates all OASIS-defined shells and modules for both DTD and XSD syntax"
22-
depends="init, clean, generate-dtd, generate-rnc-urn, generate-xsd-url, generate-xsd-urn, generate-catalogs"
23-
>
24-
25-
</target>
26-
2720
<target name="check.copyVocabs">
2821
<condition property="doCopyVocabs">
2922
<and>

build.xml

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<project basedir="." default="help" name="dita-rng2dtdxsd">
3-
<!-- NOTE: This ant script is implemented against the 2.3 version
3+
<!-- NOTE: This ant script is implemented against the 3.0.x version
44
of the DITA Open Toolkit. It may need adjustment to work
55
with other Toolkit versions.
66
-->
@@ -18,7 +18,7 @@
1818
<property name="plugin.dist" location="${basedir}/dist/plugins"/>
1919
<property name="package.dist" location="${basedir}/dist/package"/>
2020

21-
<property name="ditaver" description="The DITA version to generate (1.2, 1.3, etc.)"
21+
<property name="ditaver" description="The DITA version to generate (1.2, 1.3, 2.0, etc.)"
2222
value="1.3"
2323
/>
2424

@@ -93,7 +93,7 @@
9393
location="${src}/foreign"
9494
/>
9595

96-
<property name="usePublicIDsInShell" value="true"/><!-- For testing. True for production -->
96+
<property name="usePublicIDsInShell" value="true"/>
9797

9898
<property name="masterCatalog" location="${dita-ot-dir}/catalog-dita.xml"/>
9999

@@ -106,6 +106,7 @@
106106

107107
<makeurl property="catalogPathUrl" file="${catalogPath}"/>
108108

109+
<echo>catalogPathUri="${catalogPathUrl}"</echo>
109110

110111
<property name="debug" value="false"/>
111112
<condition property="doGenerateModules" value="${generateModules}">
@@ -116,6 +117,14 @@
116117
<isset property="generateModules"/>
117118
</not>
118119
</condition>
120+
<condition property="doGenerateStandardModules" value="${generateStandardModules}">
121+
<isset property="generateStandardModules"/>
122+
</condition>
123+
<condition property="doGenerateStandardModules" value="false">
124+
<not>
125+
<isset property="generateStandardModules"/>
126+
</not>
127+
</condition>
119128
<condition property="doGenerateCatalogs" value="${generateCatalogs}">
120129
<isset property="generateCatalogs"/>
121130
</condition>
@@ -183,6 +192,8 @@
183192
Generate the standard OASIS-defined modules as well as any other
184193
modules.
185194

195+
-Dditaver=1.2|1.3|2.0 Default is "1.3"
196+
186197
-D debug=[true|FALSE]
187198

188199
Turns on debug messages.
@@ -191,6 +202,15 @@
191202
generate any shells or modules.
192203
</echo>
193204
</target>
205+
206+
<target name="generate-all"
207+
description="Generates all shells and modules for both DTD and XSD syntax"
208+
depends="init, clean, generate-dtd, generate-xsd-url, generate-xsd-urn, generate-catalogs"
209+
>
210+
211+
</target>
212+
213+
194214

195215
<!-- NOTE: In the XSLT tasks below, I'm not sure that the
196216
<factory> specification is necessary since we're also
@@ -212,6 +232,7 @@
212232
>
213233
<arg line="-o:&quot;${manifestOutputDir}/dtd-generation-manifest.xml&quot;"/>
214234
<arg line="-it:processDir"/>
235+
<!-- <arg line="-t"/>--><!-- Uncomment this to turn on Saxon version and tracing output -->
215236
<arg line="-xsl:&quot;${dtdGenerationXsl}&quot;"/>
216237
<arg line="-catalog:&quot;${catalogPathUrl}&quot;"/>
217238
<arg line="generateCatalogs=${doGenerateCatalogs}"/>
@@ -223,7 +244,7 @@
223244
<arg line="generateModules=${doGenerateModules}"/>
224245
<arg line="generateStandardModules=${doGenerateStandardModules}"/>
225246
<arg line="generateCatalogs=${doGenerateCatalogs}"/>
226-
<arg line="catalogs=&quot;${masterCatalog}&quot;"/>
247+
<arg line="catalogs=&quot;${catalogPathUrl}&quot;"/>
227248
</java>
228249

229250
</target>
@@ -251,6 +272,7 @@
251272
<arg line="generateModules=${doGenerateModules}"/>
252273
<arg line="generateStandardModules=${doGenerateStandardModules}"/>
253274
<arg line="generateCatalogs=${doGenerateCatalogs}"/>
275+
<arg line="catalogs=&quot;${catalogPathUrl}&quot;"/>
254276
</java>
255277

256278
</target>
@@ -274,12 +296,14 @@
274296
<arg line="rootDir=${rngsrcUrl}"/>
275297
<arg line="generateModules=${doGenerateModules}"/>
276298
<arg line="generateStandardModules=${doGenerateStandardModules}"/>
299+
<arg line="catalogs=&quot;${catalogPathUrl}&quot;"/>
277300
</java>
278301
</target>
279302

280303
<target name="generate-rnc-urn"
281304
depends="init, clean"
282305
>
306+
<echo>- [WARN] RNC generation not yet fully implemented. </echo>
283307
<makeurl property="rngsrcUrl" file="${rngsrc}"/>
284308

285309
<java classname="net.sf.saxon.Transform" failonerror="true"
@@ -296,6 +320,7 @@
296320
<arg line="rootDir=${rngsrcUrl}"/>
297321
<arg line="generateModules=${doGenerateModules}"/>
298322
<arg line="generateStandardModules=${doGenerateStandardModules}"/>
323+
<arg line="catalogs=&quot;${catalogPathUrl}&quot;"/>
299324
</java>
300325
</target>
301326

@@ -315,6 +340,7 @@
315340
<arg line="ditaVersion=${ditaver}"/>
316341
<arg line="outdir=&quot;${verSpecificOutDir}&quot;"/>
317342
<arg line="catalogType=${catalogType}"/>
343+
<arg line="catalogs=&quot;${catalogPathUrl}&quot;"/>
318344
</java>
319345
</target>
320346

0 commit comments

Comments
 (0)