metanorma-generic 2.2.2 → 2.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e47c1e0506d6b40cb425824d37f34a4c48610c5a92a301305425dbca76c9952e
4
- data.tar.gz: f2505fc678139eaba373f08ae1d058e34d32e4016981536cb4f5a5a984e75ab1
3
+ metadata.gz: c46eb512e0606d0174540bb516ef208a7980b205d343ec3da8aadfbaac95c007
4
+ data.tar.gz: 34ce3a2bc7b44064fa61e3b2eadfcbd6169421429aceafa6259ef20e684a2060
5
5
  SHA512:
6
- metadata.gz: 2d708f224849accec31667209d80442776b64b7a8df211c765e51943095aa8184dfb490530465327f5b315233d54d122fb946ab2c8bf667774101c9b77e6bfbe
7
- data.tar.gz: e84fc5a09ba497091c5f415ce72336af38a274459f7f0729d0a44bf7e77e8bd873db0a308f59eda53413b79a0fcdfc17cfc8429ee1f50f4ba4c4b42c838c2e2d
6
+ metadata.gz: b0d3770ca3f7a517a0fdbf80bdbefe8f52c6fb4091b1c845562da05434a6db5e6f5a5389cd6560eb2da9c9ca60faa11eec68abb831afc4cb846e2ad9fb2d905f
7
+ data.tar.gz: 4a31f80596daacf518ca9c1a12cf7204d3dbdd8099bc582ebdc18a770bcbd2e394da33b759cbe411572d1c7be3209b2b9e25a7e0855274c2368f0ed53c6896ed
@@ -1,10 +1,5 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
3
- <include href="biblio.rng">
4
- <start>
5
- <ref name="document"/>
6
- </start>
7
- </include>
8
3
  <define name="document">
9
4
  <element name="document">
10
5
  <optional>
@@ -1125,26 +1120,4 @@
1125
1120
  </zeroOrMore>
1126
1121
  </element>
1127
1122
  </define>
1128
- <define name="ext">
1129
- <element name="ext">
1130
- <ref name="BibDataExtensionType"/>
1131
- </element>
1132
- </define>
1133
- <define name="BibDataExtensionType">
1134
- <ref name="doctype"/>
1135
- </define>
1136
- <define name="doctype">
1137
- <element name="doctype">
1138
- <ref name="DocumentType"/>
1139
- </element>
1140
- </define>
1141
- <define name="DocumentType">
1142
- <value>document</value>
1143
- </define>
1144
- <define name="BibData">
1145
- <ref name="BibliographicItem"/>
1146
- <optional>
1147
- <ref name="ext"/>
1148
- </optional>
1149
- </define>
1150
1123
  </grammar>
@@ -33,9 +33,10 @@
33
33
  <param name="pattern">([\+\-]?\d{4})((-?)((0[1-9]|1[0-2])((-?)([12]\d|0[1-9]|3[01]))?|W([0-4]\d|5[0-2])(-?[1-7])?|(00[1-9]|0[1-9]\d|[12]\d{2}|3([0-5]\d|6[1-6]))))?</param>
34
34
  </data>
35
35
  </define>
36
- <start>
37
- <ref name="bibitem"/>
38
- </start>
36
+ <!-- start = bibitem -->
37
+ <define name="BibData">
38
+ <ref name="BibliographicItem"/>
39
+ </define>
39
40
  <define name="status">
40
41
  <element name="status">
41
42
  <ref name="stage"/>
@@ -170,27 +171,30 @@
170
171
  </define>
171
172
  <define name="contributor">
172
173
  <element name="contributor">
173
- <zeroOrMore>
174
+ <oneOrMore>
174
175
  <ref name="role"/>
175
- </zeroOrMore>
176
+ </oneOrMore>
176
177
  <ref name="ContributorInfo"/>
177
178
  </element>
178
179
  </define>
179
180
  <define name="role">
180
181
  <element name="role">
181
- <optional>
182
- <attribute name="type">
183
- <choice>
184
- <value>author</value>
185
- <value>performer</value>
186
- <value>publisher</value>
187
- <value>editor</value>
188
- <value>adapter</value>
189
- <value>translator</value>
190
- <value>distributor</value>
191
- </choice>
192
- </attribute>
193
- </optional>
182
+ <attribute name="type">
183
+ <choice>
184
+ <value>author</value>
185
+ <value>performer</value>
186
+ <value>publisher</value>
187
+ <value>editor</value>
188
+ <value>adapter</value>
189
+ <value>translator</value>
190
+ <value>distributor</value>
191
+ <value>realizer</value>
192
+ <value>owner</value>
193
+ <value>authorizer</value>
194
+ <value>enabler</value>
195
+ <value>subject</value>
196
+ </choice>
197
+ </attribute>
194
198
  <zeroOrMore>
195
199
  <ref name="roledescription"/>
196
200
  </zeroOrMore>
@@ -512,6 +516,17 @@
512
516
  </define>
513
517
  <define name="localityStack">
514
518
  <element name="localityStack">
519
+ <optional>
520
+ <attribute name="connective">
521
+ <choice>
522
+ <value>and</value>
523
+ <value>or</value>
524
+ <value>from</value>
525
+ <value>to</value>
526
+ <value/>
527
+ </choice>
528
+ </attribute>
529
+ </optional>
515
530
  <zeroOrMore>
516
531
  <ref name="locality"/>
517
532
  </zeroOrMore>
@@ -524,6 +539,17 @@
524
539
  </define>
525
540
  <define name="sourceLocalityStack">
526
541
  <element name="sourceLocalityStack">
542
+ <optional>
543
+ <attribute name="connective">
544
+ <choice>
545
+ <value>and</value>
546
+ <value>or</value>
547
+ <value>from</value>
548
+ <value>to</value>
549
+ <value/>
550
+ </choice>
551
+ </attribute>
552
+ </optional>
527
553
  <zeroOrMore>
528
554
  <ref name="sourceLocality"/>
529
555
  </zeroOrMore>
@@ -626,6 +652,9 @@
626
652
  <ref name="BibItemType"/>
627
653
  </attribute>
628
654
  </optional>
655
+ <optional>
656
+ <attribute name="schema-version"/>
657
+ </optional>
629
658
  <optional>
630
659
  <ref name="fetched"/>
631
660
  </optional>
@@ -720,6 +749,9 @@
720
749
  <ref name="BibItemType"/>
721
750
  </attribute>
722
751
  </optional>
752
+ <optional>
753
+ <attribute name="schema-version"/>
754
+ </optional>
723
755
  <optional>
724
756
  <ref name="fetched"/>
725
757
  </optional>
@@ -33,13 +33,12 @@ module Metanorma
33
33
  "{{ organization_name_short }} {{ docnumeric }}"
34
34
  docid = xmldoc.at("//bibdata/docidentifier")
35
35
  id = boilerplate_isodoc(xmldoc).populate_template(template, nil)
36
- id.empty? and docid.remove or docid.children = id
36
+ (id.empty? and docid.remove) or docid.children = id
37
37
  end
38
38
 
39
39
  def doctype(node)
40
40
  d = super
41
- configuration.doctypes or return d == "article" ?
42
- (configuration.default_doctype || "standard") : d
41
+ configuration.doctypes or return d == "article" ? (configuration.default_doctype || "standard") : d
43
42
  type = configuration.default_doctype ||
44
43
  configuration.doctypes.keys.dig(0) || "standard"
45
44
  unless configuration.doctypes.keys.include? d
@@ -56,13 +55,13 @@ module Metanorma
56
55
  end
57
56
 
58
57
  def sectiontype_streamline(ret)
59
- if configuration&.termsdefs_titles&.map(&:downcase)&.include? ret
58
+ if configuration.termsdefs_titles&.map(&:downcase)&.include? ret
60
59
  "terms and definitions"
61
- elsif configuration&.symbols_titles&.map(&:downcase)&.include? ret
60
+ elsif configuration.symbols_titles&.map(&:downcase)&.include? ret
62
61
  "symbols and abbreviated terms"
63
- elsif configuration&.normref_titles&.map(&:downcase)&.include? ret
62
+ elsif configuration.normref_titles&.map(&:downcase)&.include? ret
64
63
  "normative references"
65
- elsif configuration&.bibliography_titles&.map(&:downcase)&.include? ret
64
+ elsif configuration.bibliography_titles&.map(&:downcase)&.include? ret
66
65
  "bibliography"
67
66
  else
68
67
  super
@@ -103,7 +102,7 @@ module Metanorma
103
102
  end
104
103
 
105
104
  def stage_validate(xmldoc)
106
- stages = configuration&.stage_abbreviations&.keys || return
105
+ stages = configuration.stage_abbreviations&.keys || return
107
106
  stages.empty? and return
108
107
  stage = xmldoc&.at("//bibdata/status/stage")&.text
109
108
  stages.include? stage or
@@ -1,95 +1,7 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <grammar ns="https://www.metanorma.org/ns/generic" xmlns="http://relaxng.org/ns/structure/1.0">
3
- <!--
4
- Currently we inherit from a namespaced grammar, isostandard. Until we inherit from isodoc,
5
- we cannot have a new default namespace: we will end up with a grammar with two different
6
- namespaces, one for isostandard and one for csand additions. And we do not want that.
7
- -->
8
- <include href="isodoc.rng">
9
- <start>
10
- <ref name="generic-standard"/>
11
- </start>
12
- <define name="DocumentType">
13
- <choice>
14
- <value>policy-and-procedures</value>
15
- <value>best-practices</value>
16
- <value>supporting-document</value>
17
- <value>report</value>
18
- <value>legal</value>
19
- <value>directives</value>
20
- <value>proposal</value>
21
- <value>standard</value>
22
- </choice>
23
- </define>
24
- <define name="editorialgroup">
25
- <element name="editorialgroup">
26
- <oneOrMore>
27
- <ref name="committee"/>
28
- </oneOrMore>
29
- </element>
30
- </define>
31
- <define name="BibDataExtensionType">
32
- <optional>
33
- <ref name="doctype"/>
34
- </optional>
35
- <optional>
36
- <ref name="docsubtype"/>
37
- </optional>
38
- <ref name="editorialgroup"/>
39
- <zeroOrMore>
40
- <ref name="ics"/>
41
- </zeroOrMore>
42
- <optional>
43
- <ref name="security"/>
44
- </optional>
45
- </define>
46
- </include>
47
- <define name="committee">
48
- <element name="committee">
49
- <attribute name="type">
50
- <choice>
51
- <value>technical</value>
52
- <value>provisional</value>
53
- </choice>
54
- </attribute>
55
- <text/>
56
- </element>
57
- </define>
58
- <define name="security">
59
- <element name="security">
60
- <text/>
61
- </element>
62
- </define>
63
- <define name="generic-standard">
64
- <element name="generic-standard">
65
- <attribute name="version"/>
66
- <attribute name="type">
67
- <choice>
68
- <value>semantic</value>
69
- <value>presentation</value>
70
- </choice>
71
- </attribute>
72
- <ref name="bibdata"/>
73
- <zeroOrMore>
74
- <ref name="termdocsource"/>
75
- </zeroOrMore>
76
- <optional>
77
- <ref name="misccontainer"/>
78
- </optional>
79
- <optional>
80
- <ref name="boilerplate"/>
81
- </optional>
82
- <ref name="preface"/>
83
- <oneOrMore>
84
- <ref name="sections"/>
85
- </oneOrMore>
86
- <zeroOrMore>
87
- <ref name="annex"/>
88
- </zeroOrMore>
89
- <ref name="bibliography"/>
90
- <zeroOrMore>
91
- <ref name="indexsect"/>
92
- </zeroOrMore>
93
- </element>
94
- </define>
3
+ <!-- default namespace isostandard = "https://www.metanorma.com/ns/iso" -->
4
+ <include href="biblio-standoc.rng"/>
5
+ <include href="isodoc.rng"/>
95
6
  </grammar>
7
+ <!-- end overrides -->
@@ -19,19 +19,7 @@
19
19
  -->
20
20
  <grammar xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
21
21
  <include href="reqt.rng"/>
22
- <!-- include "biblio.rnc" { } -->
23
22
  <include href="basicdoc.rng">
24
- <start>
25
- <ref name="standard-document"/>
26
- </start>
27
- <define name="doctype">
28
- <element name="doctype">
29
- <optional>
30
- <attribute name="abbreviation"/>
31
- </optional>
32
- <ref name="DocumentType"/>
33
- </element>
34
- </define>
35
23
  <define name="admonition">
36
24
  <element name="admonition">
37
25
  <attribute name="type">
@@ -117,24 +105,6 @@
117
105
  </optional>
118
106
  </element>
119
107
  </define>
120
- <define name="bibitem">
121
- <element name="bibitem">
122
- <attribute name="id">
123
- <data type="ID"/>
124
- </attribute>
125
- <optional>
126
- <attribute name="hidden">
127
- <data type="boolean"/>
128
- </attribute>
129
- </optional>
130
- <optional>
131
- <attribute name="suppress_identifier">
132
- <data type="boolean"/>
133
- </attribute>
134
- </optional>
135
- <ref name="BibliographicItem"/>
136
- </element>
137
- </define>
138
108
  <define name="section-title">
139
109
  <element name="title">
140
110
  <zeroOrMore>
@@ -205,6 +175,11 @@
205
175
  <data type="boolean"/>
206
176
  </attribute>
207
177
  </optional>
178
+ <optional>
179
+ <attribute name="style">
180
+ <ref name="XrefStyleType"/>
181
+ </attribute>
182
+ </optional>
208
183
  <ref name="XrefBody"/>
209
184
  </element>
210
185
  </define>
@@ -239,42 +214,6 @@
239
214
  <ref name="PureTextElement"/>
240
215
  </oneOrMore>
241
216
  </define>
242
- <define name="localityStack">
243
- <element name="localityStack">
244
- <optional>
245
- <attribute name="connective">
246
- <choice>
247
- <value>and</value>
248
- <value>or</value>
249
- <value>from</value>
250
- <value>to</value>
251
- <value/>
252
- </choice>
253
- </attribute>
254
- </optional>
255
- <zeroOrMore>
256
- <ref name="locality"/>
257
- </zeroOrMore>
258
- </element>
259
- </define>
260
- <define name="sourceLocalityStack">
261
- <element name="sourceLocalityStack">
262
- <optional>
263
- <attribute name="connective">
264
- <choice>
265
- <value>and</value>
266
- <value>or</value>
267
- <value>from</value>
268
- <value>to</value>
269
- <value/>
270
- </choice>
271
- </attribute>
272
- </optional>
273
- <zeroOrMore>
274
- <ref name="sourceLocality"/>
275
- </zeroOrMore>
276
- </element>
277
- </define>
278
217
  <define name="ul">
279
218
  <element name="ul">
280
219
  <attribute name="id">
@@ -818,21 +757,6 @@
818
757
  </zeroOrMore>
819
758
  </element>
820
759
  </define>
821
- <define name="BibDataExtensionType">
822
- <ref name="doctype"/>
823
- <optional>
824
- <ref name="docsubtype"/>
825
- </optional>
826
- <optional>
827
- <ref name="editorialgroup"/>
828
- </optional>
829
- <zeroOrMore>
830
- <ref name="ics"/>
831
- </zeroOrMore>
832
- <zeroOrMore>
833
- <ref name="structuredidentifier"/>
834
- </zeroOrMore>
835
- </define>
836
760
  <!-- TitleType = text -->
837
761
  <define name="sections">
838
762
  <element name="sections">
@@ -872,7 +796,7 @@
872
796
  <ref name="BasicBlock"/>
873
797
  </zeroOrMore>
874
798
  <zeroOrMore>
875
- <ref name="bibitem"/>
799
+ <ref name="doc_bibitem"/>
876
800
  <zeroOrMore>
877
801
  <ref name="note"/>
878
802
  </zeroOrMore>
@@ -1103,6 +1027,7 @@
1103
1027
  <ref name="stem"/>
1104
1028
  <ref name="index"/>
1105
1029
  <ref name="eref"/>
1030
+ <ref name="erefstack"/>
1106
1031
  <ref name="xref"/>
1107
1032
  <ref name="hyperlink"/>
1108
1033
  </choice>
@@ -1117,6 +1042,7 @@
1117
1042
  <ref name="stem"/>
1118
1043
  <ref name="index"/>
1119
1044
  <ref name="eref"/>
1045
+ <ref name="erefstack"/>
1120
1046
  <ref name="xref"/>
1121
1047
  <ref name="hyperlink"/>
1122
1048
  </choice>
@@ -1130,6 +1056,7 @@
1130
1056
  <ref name="PureTextElement"/>
1131
1057
  <ref name="index"/>
1132
1058
  <ref name="eref"/>
1059
+ <ref name="erefstack"/>
1133
1060
  <ref name="xref"/>
1134
1061
  <ref name="hyperlink"/>
1135
1062
  </choice>
@@ -1210,6 +1137,24 @@
1210
1137
  </define>
1211
1138
  </include>
1212
1139
  <!-- end overrides -->
1140
+ <define name="doc_bibitem">
1141
+ <element name="bibitem">
1142
+ <attribute name="id">
1143
+ <data type="ID"/>
1144
+ </attribute>
1145
+ <optional>
1146
+ <attribute name="hidden">
1147
+ <data type="boolean"/>
1148
+ </attribute>
1149
+ </optional>
1150
+ <optional>
1151
+ <attribute name="suppress_identifier">
1152
+ <data type="boolean"/>
1153
+ </attribute>
1154
+ </optional>
1155
+ <ref name="BibliographicItem"/>
1156
+ </element>
1157
+ </define>
1213
1158
  <define name="image" combine="choice">
1214
1159
  <element name="svg">
1215
1160
  <oneOrMore>
@@ -1228,14 +1173,6 @@
1228
1173
  <value>tag</value>
1229
1174
  </choice>
1230
1175
  </define>
1231
- <define name="docsubtype">
1232
- <element name="subdoctype">
1233
- <ref name="DocumentSubtype"/>
1234
- </element>
1235
- </define>
1236
- <define name="DocumentSubtype">
1237
- <text/>
1238
- </define>
1239
1176
  <define name="colgroup">
1240
1177
  <element name="colgroup">
1241
1178
  <oneOrMore>
@@ -1257,6 +1194,7 @@
1257
1194
  <ref name="add"/>
1258
1195
  <ref name="del"/>
1259
1196
  <ref name="span"/>
1197
+ <ref name="erefstack"/>
1260
1198
  </choice>
1261
1199
  </define>
1262
1200
  <define name="add">
@@ -1264,6 +1202,7 @@
1264
1202
  <choice>
1265
1203
  <ref name="PureTextElement"/>
1266
1204
  <ref name="eref"/>
1205
+ <ref name="erefstack"/>
1267
1206
  <ref name="stem"/>
1268
1207
  <ref name="keyword"/>
1269
1208
  <ref name="xref"/>
@@ -1276,6 +1215,7 @@
1276
1215
  <choice>
1277
1216
  <ref name="PureTextElement"/>
1278
1217
  <ref name="eref"/>
1218
+ <ref name="erefstack"/>
1279
1219
  <ref name="stem"/>
1280
1220
  <ref name="keyword"/>
1281
1221
  <ref name="xref"/>
@@ -1340,6 +1280,7 @@
1340
1280
  </optional>
1341
1281
  <choice>
1342
1282
  <ref name="eref"/>
1283
+ <ref name="erefstack"/>
1343
1284
  <ref name="xref"/>
1344
1285
  <ref name="termref"/>
1345
1286
  </choice>
@@ -1597,45 +1538,6 @@
1597
1538
  </choice>
1598
1539
  </element>
1599
1540
  </define>
1600
- <define name="editorialgroup">
1601
- <element name="editorialgroup">
1602
- <oneOrMore>
1603
- <ref name="technical-committee"/>
1604
- </oneOrMore>
1605
- </element>
1606
- </define>
1607
- <define name="technical-committee">
1608
- <element name="technical-committee">
1609
- <ref name="IsoWorkgroup"/>
1610
- </element>
1611
- </define>
1612
- <define name="IsoWorkgroup">
1613
- <optional>
1614
- <attribute name="number"/>
1615
- </optional>
1616
- <optional>
1617
- <attribute name="type"/>
1618
- </optional>
1619
- <optional>
1620
- <attribute name="identifier"/>
1621
- </optional>
1622
- <optional>
1623
- <attribute name="prefix"/>
1624
- </optional>
1625
- <text/>
1626
- </define>
1627
- <define name="ics">
1628
- <element name="ics">
1629
- <element name="code">
1630
- <text/>
1631
- </element>
1632
- <optional>
1633
- <element name="text">
1634
- <text/>
1635
- </element>
1636
- </optional>
1637
- </element>
1638
- </define>
1639
1541
  <define name="standard-document">
1640
1542
  <element name="standard-document">
1641
1543
  <attribute name="version"/>
@@ -2071,6 +1973,7 @@
2071
1973
  </element>
2072
1974
  <choice>
2073
1975
  <ref name="eref"/>
1976
+ <ref name="erefstack"/>
2074
1977
  <ref name="xref"/>
2075
1978
  <ref name="termref"/>
2076
1979
  </choice>
@@ -2466,71 +2369,6 @@
2466
2369
  </optional>
2467
2370
  </element>
2468
2371
  </define>
2469
- <define name="structuredidentifier">
2470
- <element name="structuredidentifier">
2471
- <optional>
2472
- <attribute name="type"/>
2473
- </optional>
2474
- <oneOrMore>
2475
- <element name="agency">
2476
- <text/>
2477
- </element>
2478
- </oneOrMore>
2479
- <optional>
2480
- <element name="class">
2481
- <text/>
2482
- </element>
2483
- </optional>
2484
- <element name="docnumber">
2485
- <text/>
2486
- </element>
2487
- <optional>
2488
- <element name="partnumber">
2489
- <text/>
2490
- </element>
2491
- </optional>
2492
- <optional>
2493
- <element name="edition">
2494
- <text/>
2495
- </element>
2496
- </optional>
2497
- <optional>
2498
- <element name="version">
2499
- <text/>
2500
- </element>
2501
- </optional>
2502
- <optional>
2503
- <element name="supplementtype">
2504
- <text/>
2505
- </element>
2506
- </optional>
2507
- <optional>
2508
- <element name="supplementnumber">
2509
- <text/>
2510
- </element>
2511
- </optional>
2512
- <optional>
2513
- <element name="amendment">
2514
- <text/>
2515
- </element>
2516
- </optional>
2517
- <optional>
2518
- <element name="corrigendum">
2519
- <text/>
2520
- </element>
2521
- </optional>
2522
- <optional>
2523
- <element name="language">
2524
- <text/>
2525
- </element>
2526
- </optional>
2527
- <optional>
2528
- <element name="year">
2529
- <text/>
2530
- </element>
2531
- </optional>
2532
- </element>
2533
- </define>
2534
2372
  <define name="term-clause">
2535
2373
  <element name="clause">
2536
2374
  <optional>
@@ -2691,6 +2529,7 @@
2691
2529
  <ref name="xref"/>
2692
2530
  <ref name="hyperlink"/>
2693
2531
  <ref name="eref"/>
2532
+ <ref name="erefstack"/>
2694
2533
  </choice>
2695
2534
  <oneOrMore>
2696
2535
  <element name="coords">
@@ -2738,6 +2577,7 @@
2738
2577
  <ref name="xref"/>
2739
2578
  <ref name="hyperlink"/>
2740
2579
  <ref name="eref"/>
2580
+ <ref name="erefstack"/>
2741
2581
  </choice>
2742
2582
  </element>
2743
2583
  </zeroOrMore>
@@ -2786,6 +2626,15 @@
2786
2626
  <ref name="PureTextElement"/>
2787
2627
  </oneOrMore>
2788
2628
  </define>
2629
+ <define name="XrefConnectiveType">
2630
+ <choice>
2631
+ <value>and</value>
2632
+ <value>or</value>
2633
+ <value>from</value>
2634
+ <value>to</value>
2635
+ <value/>
2636
+ </choice>
2637
+ </define>
2789
2638
  <define name="XrefTarget">
2790
2639
  <element name="location">
2791
2640
  <attribute name="target">
@@ -2794,14 +2643,36 @@
2794
2643
  </data>
2795
2644
  </attribute>
2796
2645
  <attribute name="connective">
2797
- <choice>
2798
- <value>and</value>
2799
- <value>or</value>
2800
- <value>from</value>
2801
- <value>to</value>
2802
- <value/>
2803
- </choice>
2646
+ <ref name="XrefConnectiveType"/>
2804
2647
  </attribute>
2805
2648
  </element>
2806
2649
  </define>
2650
+ <define name="XrefStyleType">
2651
+ <choice>
2652
+ <value>basic</value>
2653
+ <value>full</value>
2654
+ <value>short</value>
2655
+ <value>id</value>
2656
+ </choice>
2657
+ </define>
2658
+ <define name="erefTypeWithConnective">
2659
+ <optional>
2660
+ <attribute name="connective">
2661
+ <ref name="XrefConnectiveType"/>
2662
+ </attribute>
2663
+ </optional>
2664
+ <ref name="erefType"/>
2665
+ </define>
2666
+ <define name="erefstack">
2667
+ <element name="erefstack">
2668
+ <oneOrMore>
2669
+ <element name="eref">
2670
+ <ref name="erefTypeWithConnective"/>
2671
+ </element>
2672
+ </oneOrMore>
2673
+ </element>
2674
+ </define>
2675
+ <start>
2676
+ <ref name="standard-document"/>
2677
+ </start>
2807
2678
  </grammar>
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Generic
3
- VERSION = "2.2.2".freeze
3
+ VERSION = "2.2.4".freeze
4
4
  end
5
5
  end
@@ -19,12 +19,13 @@ Gem::Specification.new do |spec|
19
19
  spec.license = "BSD-2-Clause"
20
20
 
21
21
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
22
- f.match(%r{^(test|spec|features)/})
22
+ f.match(%r{^(test|spec|features|bin|.github)/}) \
23
+ || f.match(%r{Rakefile|bin/rspec})
23
24
  end
24
25
  spec.bindir = "exe"
25
26
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
26
27
  spec.require_paths = ["lib"]
27
- spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
28
+ spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
28
29
 
29
30
  spec.add_dependency "htmlentities", "~> 4.3.4"
30
31
  spec.add_dependency "metanorma-standoc", "~> 2.2.4"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-generic
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.2
4
+ version: 2.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-09-26 00:00:00.000000000 Z
11
+ date: 2022-11-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: htmlentities
@@ -202,8 +202,6 @@ executables: []
202
202
  extensions: []
203
203
  extra_rdoc_files: []
204
204
  files:
205
- - ".github/workflows/rake.yml"
206
- - ".github/workflows/release.yml"
207
205
  - ".gitignore"
208
206
  - ".hound.yml"
209
207
  - ".rubocop.yml"
@@ -211,10 +209,6 @@ files:
211
209
  - Gemfile
212
210
  - LICENSE
213
211
  - README.adoc
214
- - Rakefile
215
- - bin/console
216
- - bin/rspec
217
- - bin/setup
218
212
  - lib/asciidoctor/generic.rb
219
213
  - lib/asciidoctor/generic/converter.rb
220
214
  - lib/asciidoctor/generic/deprecated.rb
@@ -266,14 +260,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
266
260
  requirements:
267
261
  - - ">="
268
262
  - !ruby/object:Gem::Version
269
- version: 2.5.0
263
+ version: 2.7.0
270
264
  required_rubygems_version: !ruby/object:Gem::Requirement
271
265
  requirements:
272
266
  - - ">="
273
267
  - !ruby/object:Gem::Version
274
268
  version: '0'
275
269
  requirements: []
276
- rubygems_version: 3.1.6
270
+ rubygems_version: 3.3.7
277
271
  signing_key:
278
272
  specification_version: 4
279
273
  summary: Metanorma template gem for customisation.
@@ -1,15 +0,0 @@
1
- # Auto-generated by Cimas: Do not edit it manually!
2
- # See https://github.com/metanorma/cimas
3
- name: rake
4
-
5
- on:
6
- push:
7
- branches: [ master, main ]
8
- tags: [ v* ]
9
- pull_request:
10
-
11
- jobs:
12
- notify:
13
- uses: metanorma/ci/.github/workflows/mn-processor-rake.yml@main
14
- secrets:
15
- pat_token: ${{ secrets.METANORMA_CI_PAT_TOKEN }}
@@ -1,24 +0,0 @@
1
- # Auto-generated by Cimas: Do not edit it manually!
2
- # See https://github.com/metanorma/cimas
3
- name: release
4
-
5
- on:
6
- workflow_dispatch:
7
- inputs:
8
- next_version:
9
- description: |
10
- Next release version. Possible values: x.y.z, major, minor, patch or pre|rc|etc
11
- required: true
12
- default: 'skip'
13
- push:
14
- tags: [ v* ]
15
-
16
- jobs:
17
- release:
18
- uses: metanorma/ci/.github/workflows/rubygems-release.yml@main
19
- with:
20
- next_version: ${{ github.event.inputs.next_version }}
21
- secrets:
22
- rubygems-api-key: ${{ secrets.METANORMA_CI_RUBYGEMS_API_KEY }}
23
- pat_token: ${{ secrets.METANORMA_CI_PAT_TOKEN }}
24
-
data/Rakefile DELETED
@@ -1,6 +0,0 @@
1
- require "bundler/gem_tasks"
2
- require "rspec/core/rake_task"
3
-
4
- RSpec::Core::RakeTask.new(:spec)
5
-
6
- task :default => :spec
data/bin/console DELETED
@@ -1,14 +0,0 @@
1
- #!/usr/bin/env ruby
2
-
3
- require "bundler/setup"
4
- require "metanorma/acme"
5
-
6
- # You can add fixtures and/or initialization code here to make experimenting
7
- # with your gem easier. You can also use a different console, if you like.
8
-
9
- # (If you use this, don't forget to add pry to your Gemfile!)
10
- # require "pry"
11
- # Pry.start
12
-
13
- require "irb"
14
- IRB.start(__FILE__)
data/bin/rspec DELETED
@@ -1,17 +0,0 @@
1
- #!/usr/bin/env ruby
2
-
3
- # This file was generated by Bundler.
4
- #
5
- # The application 'rspec' is installed as part of a gem, and
6
- # this file is here to facilitate running it.
7
- #
8
-
9
- require "pathname"
10
- ENV["BUNDLE_GEMFILE"] ||= File.expand_path(
11
- "../../Gemfile", Pathname.new(__FILE__).realpath
12
- )
13
-
14
- require "rubygems"
15
- require "bundler/setup"
16
-
17
- load Gem.bin_path("rspec-core", "rspec")
data/bin/setup DELETED
@@ -1,8 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -euo pipefail
3
- IFS=$'\n\t'
4
- set -vx
5
-
6
- bundle install
7
-
8
- # Do any other automated setup that you need to do here