Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
peterstadler committed Aug 25, 2019
2 parents bc46290 + aa58db4 commit 7577c2b
Show file tree
Hide file tree
Showing 66 changed files with 16,902 additions and 10,783 deletions.
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,12 @@ Files for documenting the Digital Edition of the [Carl-Maria-von-Weber-Gesamtaus
Contents
--------

* `schema`: RelaxNG schemata, generated with the [TEI XSL Stylesheets](https://github.com/TEIC/Stylesheets) [1] from the ODD files below. For convenience, an `ANT build file` is provided that documents the transformations. There are subfolders for English and German schemas which should only differ in the language of documentation (e.g. element and attribute descriptions)
* `schema`: RelaxNG schemata, generated with the [TEI XSL Stylesheets](https://github.com/TEIC/Stylesheets) from the ODD files below. For convenience, an `ANT build file` is provided that documents the transformations. There are subfolders for English and German schemas which should only differ in the language of documentation (e.g. element and attribute descriptions)
* `src`: source ODD files
* `Guidelines`: the WeGA Guidelines chapters. The main file is `guidelines-de.xml` which x-includes all chapters and schemaSpecs.
* `Specs`: the various schemaSpecs for the different document types. There are two special files: `common-specs.odd.xml` which provides all common specifications grouped into `specGrp`s (which are then referenced by the other schemaSpecs) and `schemaSpec-wega_all.odd.xml` which is a compiled super set of all the specific schemaSpecs.
* `compiled-ODD`: the compiled (= processed with [`odd2odd.xsl`](https://github.com/TEIC/Stylesheets/blob/dev/odds/odd2odd.xsl)) ODDs that include the full specifications and can serve as a new source for the [_chaining of ODDs_](https://wiki.tei-c.org/index.php/ODD_chaining).

[1] As of 2017-06-30 there is an issue in the TEI XSL Stylesheets with multiple schemaSpecs which is used here. More details and a patch can be found at the [GitHub issue 249](https://github.com/TEIC/Stylesheets/issues/249).

License
-------
Expand Down
2 changes: 1 addition & 1 deletion build.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ compiledODD.dir=compiled-ODD
stylesheets.dir=/Users/pstadler/repos/Stylesheets

# Path to local TEI p5subset.xml (get the latest release from http://sourceforge.net/projects/tei/files/TEI-P5-all/)
tei.source=/Users/pstadler/static/tei-3.4.0/xml/tei/odd/p5subset.xml
tei.source=/Users/pstadler/static/tei-3.6.0/xml/tei/odd/p5subset.xml

# Path to local MEI driver.xml (get the latest release from https://code.google.com/p/music-encoding/downloads/list)
mei.source=/Users/pstadler/static/MEI2013_v2.1.1/source/driver.xml
957 changes: 433 additions & 524 deletions compiled-ODD/guidelines-de-wegaBiblio.compiled.xml

Large diffs are not rendered by default.

604 changes: 347 additions & 257 deletions compiled-ODD/guidelines-de-wegaDiaries.compiled.xml

Large diffs are not rendered by default.

1,194 changes: 688 additions & 506 deletions compiled-ODD/guidelines-de-wegaDocuments.compiled.xml

Large diffs are not rendered by default.

1,115 changes: 607 additions & 508 deletions compiled-ODD/guidelines-de-wegaLetters.compiled.xml

Large diffs are not rendered by default.

1,740 changes: 1,186 additions & 554 deletions compiled-ODD/guidelines-de-wegaNews.compiled.xml

Large diffs are not rendered by default.

954 changes: 707 additions & 247 deletions compiled-ODD/guidelines-de-wegaOrgs.compiled.xml

Large diffs are not rendered by default.

1,113 changes: 879 additions & 234 deletions compiled-ODD/guidelines-de-wegaPersons.compiled.xml

Large diffs are not rendered by default.

717 changes: 435 additions & 282 deletions compiled-ODD/guidelines-de-wegaPlaces.compiled.xml

Large diffs are not rendered by default.

1,165 changes: 546 additions & 619 deletions compiled-ODD/guidelines-de-wegaThematicCommentaries.compiled.xml

Large diffs are not rendered by default.

1,797 changes: 1,050 additions & 747 deletions compiled-ODD/guidelines-de-wegaVar.compiled.xml

Large diffs are not rendered by default.

110 changes: 65 additions & 45 deletions compiled-ODD/guidelines-de-wegaWorks.compiled.xml

Large diffs are not rendered by default.

1,109 changes: 619 additions & 490 deletions compiled-ODD/guidelines-de-wegaWritings.compiled.xml

Large diffs are not rendered by default.

1,217 changes: 700 additions & 517 deletions compiled-ODD/guidelines-de-wega_all.compiled.xml

Large diffs are not rendered by default.

50 changes: 30 additions & 20 deletions schema/de/wegaBiblio.isosch
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<schema xmlns="http://purl.oclc.org/dsdl/schematron" queryBinding="xslt2">
<title>ISO Schematron rules</title>
<!-- This file generated 2019-01-04T09:03:48Z by 'extract-isosch.xsl'. -->
<!-- This file generated 2019-08-22T08:54:36Z by 'extract-isosch.xsl'. -->

<!-- ********************* -->
<!-- namespaces, declared: -->
Expand Down Expand Up @@ -38,9 +38,9 @@
</pattern>
<pattern id="schematron-constraint-wegaBiblio-att.datable-calendar-calendar-5">
<rule context="tei:*[@calendar]">
<assert test="string-length(.) gt 0">
@calendar indicates the system or calendar to which the date represented by the content of this element
belongs, but this <name/> element has no textual content.</assert>
<assert test="string-length(.) gt 0"> @calendar indicates the system or calendar to
which the date represented by the content of this element belongs, but this
<name/> element has no textual content.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-att.typed-subtypeTyped-6">
Expand Down Expand Up @@ -185,82 +185,92 @@ belongs, but this <name/> element has no textual content.</assert>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-note-notesStmt-notes-19">
<rule context="tei:note[parent::tei:notesStmt]">
<assert test="@type=('editorial', 'summary', 'thematicCom', 'incipit')">Within the notesStmt only 'editorial', 'summary', or 'thematicCom' are allowed for @type on note.</assert>
<assert test="@type=('editorial', 'summary', 'thematicCom', 'incipit', 'textConst')">Within the notesStmt only 'editorial', 'summary', 'textConst', or 'thematicCom' are allowed for @type on note.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-analytic-analyticTitle-20">
<pattern id="schematron-constraint-wegaBiblio-note-text-notes-20">
<rule context="tei:note[not(parent::tei:notesStmt)]">
<report test="@type=('editorial', 'summary', 'incipit')">The note types 'editorial', 'summary', or 'thematicCom' are not allowed within the text section but only in the notesStmt.</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-note-structured-content-notes-21">
<rule context="tei:note[parent::tei:notesStmt][tei:p|tei:list|tei:table]">
<report test="text()[matches(., '\w')] or *[not(self::tei:p or self::tei:list or self::tei:table)]">There must be no mixed content when a tei:p, tei:list, or tei:table is present.</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-analytic-analyticTitle-22">
<rule context="tei:analytic">
<report test="tei:title/@level and not(tei:title/@level='a')">a title within analytic must have a @level='a'</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-monogr-monogrTitle-21">
<pattern id="schematron-constraint-wegaBiblio-monogr-monogrTitle-23">
<rule context="tei:monogr">
<report test="tei:title/@level and not(tei:title/@level=('j','m','u'))">a title within monogr must have a @level='j|m'</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-series-seriesTitle-22">
<pattern id="schematron-constraint-wegaBiblio-series-seriesTitle-24">
<rule context="tei:series">
<report test="tei:title/@level and not(tei:title/@level='s')">a title within series must have a @level='s'</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-author-sameAs-sameAs-reference-23">
<pattern id="schematron-constraint-wegaBiblio-author-sameAs-sameAs-reference-25">
<rule context="tei:author[@sameAs]">
<assert test="id(substring(@sameAs,2)) or starts-with(@sameAs, 'wega:')">There must be an element with the xml:id = "<value-of select="substring(@sameAs,2)"/>" which is the target of this @sameAs.</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-title-duplicate-title-24">
<pattern id="schematron-constraint-wegaBiblio-title-duplicate-title-26">
<rule context="tei:title[following-sibling::tei:title]">
<let name="level" value="@level"/>
<let name="type" value="string(@type)"/>
<let name="lang" value="string(@xml:lang)"/>
<report test="following-sibling::tei:title[@level = $level][string(@xml:lang) = $lang][string(@type) = $type]">Following title without differing @type or xml:lang attribute</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-title-punctuation-mark-25">
<pattern id="schematron-constraint-wegaBiblio-title-punctuation-mark-27">
<rule context="tei:title">
<report test="matches(normalize-space(self::tei:title), '[\.,;]$') and not(matches(normalize-space(self::tei:title), '((\p{Lu})|(\setc)|(\sal)|([\s\.]a)|(\sBl)|(\sAufl))\.$'))">Found a non-valid punctuation mark at the end of <name/>
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-imprint-duplicate-biblScope-type-26">
<pattern id="schematron-constraint-wegaBiblio-imprint-duplicate-biblScope-type-28">
<rule context="tei:imprint">
<report test="count(distinct-values(tei:biblScope/@type)) ne count(tei:biblScope/@type)">duplicate value for biblScope</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-styleguide-document-node-content-27">
<pattern id="schematron-constraint-wegaBiblio-styleguide-document-node-content-29">
<rule context="document-node()">
<report test="count(processing-instruction()) ne 2">WeGA styleguide error: there should exactly be two processing instructions before the root element</report>
<report test="comment()">WeGA styleguide error: there should be no comments outside the root element</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-whitespaceOnlyContent-28">
<pattern id="schematron-constraint-wegaBiblio-whitespaceOnlyContent-30">
<rule context="tei:surname | tei:forename | tei:persName | tei:author[not(@sameAs)] | tei:occupation | tei:settlement | tei:country | tei:region | tei:rs | tei:workName | tei:characterName | tei:hi[not(.//tei:gap)] | tei:head | tei:note[not(@type=('thematicCom'))] | tei:placeName | tei:title | tei:seg | tei:item[not(@* or *)]">
<report test="normalize-space(.) = ''">
<name/> has whitespace only content</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-elementStartsWithWhitespace-29">
<pattern id="schematron-constraint-wegaBiblio-elementStartsWithWhitespace-31">
<rule context="tei:surname | tei:forename | tei:persName[not(@type)] | tei:author | tei:occupation | tei:settlement | tei:country | tei:region | tei:rs | tei:workName | tei:characterName | tei:hi | tei:placeName[not(parent::tei:address or parent::tei:birth or parent::tei:death)]">
<report test="matches(.,'^\s') and (node()[1] = text()[1])">whitespace at the beginning of element <name/>
</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-untrimmedAttributeValues-30">
<pattern id="schematron-constraint-wegaBiblio-untrimmedAttributeValues-32">
<rule context="*">
<report test="some $i in @* satisfies string-length(normalize-unicode(normalize-space(replace($i, ' | | | ', ' ')))) ne string-length($i)">There is some whitespace here at the beginning or end of some attribute value.</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-wegaTargets-31">
<pattern id="schematron-constraint-wegaBiblio-wegaTargets-33">
<rule context="*[starts-with(@target, 'wega:')]">
<assert test="matches(@target, '^wega:A[0-9A-F]{6}(#.+)?$')">"wega"-prefixed URIs must follow the pattern "wega:A002068" (i.e. without any file extension)</assert>
<assert test="matches(@target, '^wega:A[0-9A-F]{6}(#.+)?(\s+wega:A[0-9A-F]{6}(#.+)?)*$')">"wega"-prefixed URIs must follow the pattern "wega:A002068" (i.e. without any file extension)</assert>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-emojiCheck-32">
<pattern id="schematron-constraint-wegaBiblio-emojiCheck-34">
<rule context="*[some $i in text() satisfies normalize-space($i) ne '']">
<report test="matches(., '[⌚-⌛]|[⏩-⏬]|[⏰]|[⏳]|[◽-◾]|[☔-☕]|[♈-♓]|[♿]|[⚓]|[⚡]|[⚪-⚫]|[⚽-⚾]|[⛄-⛅]|[⛎]|[⛔]|[⛪]|[⛲-⛳]|[⛵]|[⛺]|[⛽]|[✅]|[✊-✋]|[✨]|[❌]|[❎]|[❓-❕]|[❗]|[➕-➗]|[➰]|[➿]|[⬛-⬜]|[⭐]|[⭕]|[🀄]|[🃏]|[🆎]|[🆑-🆚]|[🇦-🇿]|[🈁]|[🈚]|[🈯]|[🈲-🈶]|[🈸-🈺]|[🉐-🉑]|[🌀-🌠]|[🌭-🌯]|[🌰-🌵]|[🌷-🍼]|[🍾-🍿]|[🎀-🎓]|[🎠-🏄]|[🏅]|[🏆-🏊]|[🏏-🏓]|[🏠-🏰]|[🏴]|[🏸-🏿]|[🐀-🐾]|[👀]|[👂-📷]|[📸]|[📹-📼]|[📿]|[🔀-🔽]|[🕋-🕎]|[🕐-🕧]|[🕺]|[🖕-🖖]|[🖤]|[🗻-🗿]|[😀]|[😁-😐]|[😑]|[😒-😔]|[😕]|[😖]|[😗]|[😘]|[😙]|[😚]|[😛]|[😜-😞]|[😟]|[😠-😥]|[😦-😧]|[😨-😫]|[😬]|[😭]|[😮-😯]|[😰-😳]|[😴]|[😵-🙀]|[🙁-🙂]|[🙃-🙄]|[🙅-🙏]|[🚀-🛅]|[🛌]|[🛐]|[🛑-🛒]|[🛕]|[🛫-🛬]|[🛴-🛶]|[🛷-🛸]|[🛹]|[🛺]|[🟠-🟫]|[🤍-🤏]|[🤐-🤘]|[🤙-🤞]|[🤟]|[🤠-🤧]|[🤨-🤯]|[🤰]|[🤱-🤲]|[🤳-🤺]|[🤼-🤾]|[🤿]|[🥀-🥅]|[🥇-🥋]|[🥌]|[🥍-🥏]|[🥐-🥞]|[🥟-🥫]|[🥬-🥰]|[🥱]|[🥳-🥶]|[🥺]|[🥻]|[🥼-🥿]|[🦀-🦄]|[🦅-🦑]|[🦒-🦗]|[🦘-🦢]|[🦥-🦪]|[🦮-🦯]|[🦰-🦹]|[🦺-🦿]|[🧀]|[🧁-🧂]|[🧃-🧊]|[🧍-🧏]|[🧐-🧦]|[🧧-🧿]|[🩰-🩳]|[🩸-🩺]|[🪀-🪂]|[🪐-🪕]')">Text contains characters with Emoji presentation as default.</report>
</rule>
</pattern>
<pattern id="schematron-constraint-wegaBiblio-att.wega.rend-underline-n-33">
<pattern id="schematron-constraint-wegaBiblio-att.wega.rend-underline-n-35">
<rule context="*:hi[@n] | *:rend[@n]">
<report test="@rend ne 'underline'">The @n-attribute is only supported in combination with @rend='underline'</report>
</rule>
Expand Down
Loading

0 comments on commit 7577c2b

Please sign in to comment.