[rfc-i] xml2rfc v3: publish the relax ng schema of draft-hoffman-xml2rfc-15

Miek Gieben miek at miek.nl
Mon Jan 19 14:11:31 PST 2015


[ Quoting <julian.reschke at greenbytes> in "Re: [rfc-i] xml2rfc v3: publish the..." ]
>On 2015-01-19 12:57, Miek Gieben wrote:
>>Hello,
>>
>>Can we publish the relax NG schema somewhere besides it being in the draft?
>>I want to validate the XML output of my markdown parser and cutting and
>>pasting the schema from the text is tedious and error prone.
>>(Alternatively it could be prefixed with something greppable)
>>
>>Thanks!
>
>You can easily extract the RNC version from the XML source.
>
>Or just use <http://trac.tools.ietf.org/tools/xml2rfc/trac/browser/vocabulary/v3/latest/xml2rfcv3.rng>.

Ok, there is def. something wrong there. Taking the original rnc:

% jing -c xml2rfcv3.rnc
/home/miek/g/src/github.com/miekg/mmark/xml2rfcv3.rnc:189:3: error: group of "string" or "data" element

Applying the following diff:

% diff -u xml2rfcv3.rnc /tmp/xml2rfc3.rnc
--- xml2rfcv3.rnc       2015-01-19 22:07:42.945724345 +0000
+++ /tmp/xml2rfc3.rnc   2015-01-19 22:07:39.365724456 +0000
@@ -190,11 +190,6 @@
      attribute anchor { xsd:ID }?,
      attribute hangText { text }?,
      attribute pn { text }?,
-    ([ a:defaultValue = "false" ] attribute keepwithnext { text },
-     ("false" | "true"))?,
-    ([ a:defaultValue = "false" ]
-     attribute keepwithprevious { text },
-     ("false" | "true"))?,
      (text
       | b
       | bcp14

% jing -c /tmp/xml2rfc3.rnc
<no errors>

I'm by no means an export in rnc, so I have no idea what to fix there.

/Miek

--
Miek Gieben



More information about the rfc-interest mailing list