i'm thinking of committing the attached patch, which will make
<resources/> and <modules/> optional, but forces them to have at least
one resource or module element inside.
andreas, since you changed that code: is there a particular reason for
the current behaviour, i.e. mandate the wrappers and make the content
elements optional? i find it a little counter-intuitive...
regards,
jörn
--
Jörn Nettingsmeier
Kurt is up in heaven now.
Index: pubs/blog/config/publication.xml
===================================================================
--- pubs/blog/config/publication.xml (revision 534971)
+++ pubs/blog/config/publication.xml (working copy)
@@ -37,6 +37,5 @@
<resource-type name="entry" workflow="workflow.xml"/>
<resource-type name="sidebar" workflow="workflow.xml"/>
</resource-types>
- <modules/>
</publication>
Index: resources/build/publication.rng
===================================================================
--- resources/build/publication.rng (revision 534971)
+++ resources/build/publication.rng (working copy)
@@ -18,10 +18,10 @@
<!--
This RELAX NG grammar defines the configuration file of a. Lenya publication.
- Configuration files must be located under "$YOURPUBROOT/$PUBNAME/config/publication.xml".
+ Configuration files must be located under "$PUB_HOME/$PUBNAME/config/publication.xml".
This schema is new as of 2007-02-23. It is NOT backwards-compatible. It combines the
- contents of $YOURPUBROOT/$PUBNAME/publication.xml and $YOURPUBROOT/$PUBNAME/config/publication.xml.
+ contents of $PUB_HOME/$PUBNAME/publication.xml and $PUB_HOME/$PUBNAME/config/publication.xconf.
The publication.xml file is parsed by:
@@ -162,22 +162,26 @@
</element>
<element name="document-builder"><attribute name="name"><data type="string"/></attribute></element>
<element name="site-manager"><attribute name="name"><data type="string"/></attribute></element>
- <element name="resource-types">
- <zeroOrMore>
- <element name="resource-type">
- <attribute name="name"><ref name="resourceTypeName"/></attribute>
- <attribute name="workflow"><ref name="workflowUri"/></attribute>
- </element>
- </zeroOrMore>
- </element>
- <element name="modules">
- <zeroOrMore>
- <element name="module">
- <attribute name="name"><ref name="moduleName"/></attribute>
- </element>
- </zeroOrMore>
- </element>
<optional>
+ <element name="resource-types">
+ <oneOrMore>
+ <element name="resource-type">
+ <attribute name="name"><ref name="resourceTypeName"/></attribute>
+ <attribute name="workflow"><ref name="workflowUri"/></attribute>
+ </element>
+ </oneOrMore>
+ </element>
+ </optional>
+ <optional>
+ <element name="modules">
+ <oneOrMore>
+ <element name="module">
+ <attribute name="name"><ref name="moduleName"/></attribute>
+ </element>
+ </oneOrMore>
+ </element>
+ </optional>
+ <optional>
<element name="breadcrumb-prefix"><data type="string"/></element>
</optional>
<optional>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]