metanorma-iso 2.8.7 → 2.8.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/isodoc/iso/html/html_iso_titlepage.html +6 -0
- data/lib/isodoc/iso/html/word_iso_titlepage-dis.html +10 -0
- data/lib/isodoc/iso/html/word_iso_titlepage-prf.html +10 -0
- data/lib/isodoc/iso/html/word_iso_titlepage.html +10 -0
- data/lib/isodoc/iso/i18n-de.yaml +1 -0
- data/lib/isodoc/iso/i18n-en.yaml +3 -0
- data/lib/isodoc/iso/i18n-fr.yaml +3 -0
- data/lib/isodoc/iso/i18n-ru.yaml +3 -0
- data/lib/isodoc/iso/i18n-zh-Hans.yaml +1 -0
- data/lib/isodoc/iso/iso.amendment.xsl +717 -140
- data/lib/isodoc/iso/iso.international-standard.xsl +717 -140
- data/lib/isodoc/iso/metadata.rb +12 -0
- data/lib/metanorma/iso/base.rb +3 -3
- data/lib/metanorma/iso/biblio-standoc.rng +13 -0
- data/lib/metanorma/iso/biblio.rng +19 -12
- data/lib/metanorma/iso/cleanup.rb +1 -1
- data/lib/metanorma/iso/cleanup_biblio.rb +9 -7
- data/lib/metanorma/iso/converter.rb +1 -1
- data/lib/metanorma/iso/front.rb +19 -14
- data/lib/metanorma/iso/front_contributor.rb +1 -1
- data/lib/metanorma/iso/front_id.rb +7 -3
- data/lib/metanorma/iso/processor.rb +3 -5
- data/lib/metanorma/iso/relaton-iso.rng +2 -0
- data/lib/metanorma/iso/section.rb +1 -1
- data/lib/metanorma/iso/validate.rb +3 -2
- data/lib/metanorma/iso/validate_image.rb +1 -1
- data/lib/metanorma/iso/validate_list.rb +1 -1
- data/lib/metanorma/iso/validate_requirements.rb +1 -1
- data/lib/metanorma/iso/validate_section.rb +1 -1
- data/lib/metanorma/iso/validate_style.rb +1 -1
- data/lib/metanorma/iso/validate_title.rb +1 -1
- data/lib/metanorma/iso/version.rb +2 -2
- data/metanorma-iso.gemspec +2 -2
- metadata +2 -2
data/lib/isodoc/iso/metadata.rb
CHANGED
|
@@ -67,6 +67,7 @@ module IsoDoc
|
|
|
67
67
|
# French titles in the same document
|
|
68
68
|
PART_LABEL = { en: "Part", fr: "Partie", ru: "Часть" }.freeze
|
|
69
69
|
AMD_LABEL = { en: "AMENDMENT", fr: "AMENDMENT", ru: "ПОПРАВКА" }.freeze
|
|
70
|
+
ADD_LABEL = { en: "ADDENDUM", fr: "ADDITIF", ru: "ДОПОЛНЕНИЕ" }.freeze
|
|
70
71
|
CORR_LABEL = { en: "TECHNICAL CORRIGENDUM",
|
|
71
72
|
fr: "RECTIFICATIF TECHNIQUE",
|
|
72
73
|
ru: "ТЕХНИЧЕСКОЕ ИСПРАВЛЕНИЕ" }.freeze
|
|
@@ -93,6 +94,10 @@ module IsoDoc
|
|
|
93
94
|
"#{self.class::AMD_LABEL[lang.to_sym]} #{titlenums[:amd]}"
|
|
94
95
|
end
|
|
95
96
|
|
|
97
|
+
def add_prefix(titlenums, lang)
|
|
98
|
+
"#{self.class::ADD_LABEL[lang.to_sym]} #{titlenums[:add]}"
|
|
99
|
+
end
|
|
100
|
+
|
|
96
101
|
def corr_prefix(titlenums, lang)
|
|
97
102
|
"#{self.class::CORR_LABEL[lang.to_sym]} #{titlenums[:corr]}"
|
|
98
103
|
end
|
|
@@ -115,6 +120,7 @@ module IsoDoc
|
|
|
115
120
|
{ part: isoxml.at(ns("#{prefix}/@part")),
|
|
116
121
|
subpart: isoxml.at(ns("#{prefix}/@subpart")),
|
|
117
122
|
amd: isoxml.at(ns("#{prefix}/@amendment")),
|
|
123
|
+
add: isoxml.at(ns("#{prefix}/@addendum")),
|
|
118
124
|
corr: isoxml.at(ns("#{prefix}/@corrigendum")) }
|
|
119
125
|
end
|
|
120
126
|
|
|
@@ -126,6 +132,8 @@ module IsoDoc
|
|
|
126
132
|
part: isoxml.at(ns("//bibdata/title[@type='title-part' and " \
|
|
127
133
|
"@language='#{lang}']")),
|
|
128
134
|
amd: isoxml.at(ns("//bibdata/title[@type='title-amd' and " \
|
|
135
|
+
"@language='#{lang}']")),
|
|
136
|
+
add: isoxml.at(ns("//bibdata/title[@type='title-add' and " \
|
|
129
137
|
"@language='#{lang}']")) }
|
|
130
138
|
end
|
|
131
139
|
|
|
@@ -146,6 +154,8 @@ module IsoDoc
|
|
|
146
154
|
set(:doctitleamdlabel, amd_prefix(tn, lang)) if tn[:amd]
|
|
147
155
|
set(:doctitleamd, tp[:amd].children.to_xml) if tp[:amd]
|
|
148
156
|
set(:doctitlecorrlabel, corr_prefix(tn, lang)) if tn[:corr]
|
|
157
|
+
set(:doctitleaddlabel, add_prefix(tn, lang)) if tn[:add]
|
|
158
|
+
set(:doctitleadd, tp[:add].children.to_xml) if tp[:add]
|
|
149
159
|
end
|
|
150
160
|
|
|
151
161
|
def subtitle(isoxml, _out)
|
|
@@ -161,6 +171,8 @@ module IsoDoc
|
|
|
161
171
|
tp[:part] and set(:docsubtitlepart, tp[:part].children.to_xml)
|
|
162
172
|
set(:docsubtitleamdlabel, amd_prefix(tn, lang)) if tn[:amd]
|
|
163
173
|
set(:docsubtitleamd, tp[:amd].children.to_xml) if tp[:amd]
|
|
174
|
+
set(:docsubtitleaddlabel, add_prefix(tn, lang)) if tn[:add]
|
|
175
|
+
set(:docsubtitleadd, tp[:add].children.to_xml) if tp[:add]
|
|
164
176
|
set(:docsubtitlecorrlabel, corr_prefix(tn, lang)) if tn[:corr]
|
|
165
177
|
end
|
|
166
178
|
|
data/lib/metanorma/iso/base.rb
CHANGED
|
@@ -8,7 +8,7 @@ require "fileutils"
|
|
|
8
8
|
require_relative "processor"
|
|
9
9
|
|
|
10
10
|
module Metanorma
|
|
11
|
-
module
|
|
11
|
+
module Iso
|
|
12
12
|
class Converter < Standoc::Converter
|
|
13
13
|
XML_ROOT_TAG = "iso-standard".freeze
|
|
14
14
|
XML_NAMESPACE = "https://www.metanorma.org/ns/iso".freeze
|
|
@@ -83,12 +83,12 @@ module Metanorma
|
|
|
83
83
|
|
|
84
84
|
def document_scheme(node)
|
|
85
85
|
r = node.attr("document-scheme") and return r
|
|
86
|
-
r = node.attr("copyright-year")&.to_i or return
|
|
86
|
+
r = node.attr("copyright-year")&.to_i or return DOCUMENT_SCHEMES[-1]
|
|
87
87
|
DOCUMENT_SCHEMES.each_index do |i|
|
|
88
88
|
i.zero? and next
|
|
89
89
|
r < DOCUMENT_SCHEMES[i] and return DOCUMENT_SCHEMES[i - 1].to_s
|
|
90
90
|
end
|
|
91
|
-
|
|
91
|
+
DOCUMENT_SCHEMES[-1]
|
|
92
92
|
end
|
|
93
93
|
|
|
94
94
|
def outputs(node, ret)
|
|
@@ -72,6 +72,9 @@ standards defining organization, and that is rendered in a distinct manner</a:do
|
|
|
72
72
|
from other documents in the same doctype</a:documentation>
|
|
73
73
|
</ref>
|
|
74
74
|
</optional>
|
|
75
|
+
<ref name="flavor">
|
|
76
|
+
<a:documentation>Flavour of Metanorma used to process this document</a:documentation>
|
|
77
|
+
</ref>
|
|
75
78
|
<optional>
|
|
76
79
|
<ref name="editorialgroup">
|
|
77
80
|
<a:documentation>Groups associated with the production of the standards document, typically within
|
|
@@ -113,6 +116,16 @@ a standards definition organization</a:documentation>
|
|
|
113
116
|
<define name="DocumentSubtype">
|
|
114
117
|
<text/>
|
|
115
118
|
</define>
|
|
119
|
+
<define name="flavor">
|
|
120
|
+
<element name="flavor">
|
|
121
|
+
<ref name="MetanormaFlavor"/>
|
|
122
|
+
</element>
|
|
123
|
+
</define>
|
|
124
|
+
<define name="MetanormaFlavor">
|
|
125
|
+
<a:documentation>This is in fact an enum, as of this writing: standoc iso generic ietf ieee itu nist ogc csa cc iho ribose jis iec bsi bipm plateau.
|
|
126
|
+
However we prefer not to hardcode it, given ongoing extension.</a:documentation>
|
|
127
|
+
<text/>
|
|
128
|
+
</define>
|
|
116
129
|
<define name="editorialgroup">
|
|
117
130
|
<a:documentation>A group associated with the production of the standards document, typically within
|
|
118
131
|
a standards definition organization</a:documentation>
|
|
@@ -1382,18 +1382,7 @@ Applies whether the resource has already been created or not, and whether it is
|
|
|
1382
1382
|
<define name="bdate">
|
|
1383
1383
|
<a:documentation>Significant date in the lifecycle of the bibliographic item, including its production and its access</a:documentation>
|
|
1384
1384
|
<element name="date">
|
|
1385
|
-
<
|
|
1386
|
-
<a:documentation>The phase of the production of or access to a bibliographic item</a:documentation>
|
|
1387
|
-
<choice>
|
|
1388
|
-
<ref name="BibliographicDateType"/>
|
|
1389
|
-
<text/>
|
|
1390
|
-
</choice>
|
|
1391
|
-
</attribute>
|
|
1392
|
-
<optional>
|
|
1393
|
-
<attribute name="text">
|
|
1394
|
-
<a:documentation>An optional textual description of the date, especially when a Gregorian date is not applicable</a:documentation>
|
|
1395
|
-
</attribute>
|
|
1396
|
-
</optional>
|
|
1385
|
+
<ref name="bDateAttributes"/>
|
|
1397
1386
|
<optional>
|
|
1398
1387
|
<choice>
|
|
1399
1388
|
<group>
|
|
@@ -1416,6 +1405,20 @@ Applies whether the resource has already been created or not, and whether it is
|
|
|
1416
1405
|
</optional>
|
|
1417
1406
|
</element>
|
|
1418
1407
|
</define>
|
|
1408
|
+
<define name="bDateAttributes">
|
|
1409
|
+
<attribute name="type">
|
|
1410
|
+
<a:documentation>The phase of the production of or access to a bibliographic item</a:documentation>
|
|
1411
|
+
<choice>
|
|
1412
|
+
<ref name="BibliographicDateType"/>
|
|
1413
|
+
<text/>
|
|
1414
|
+
</choice>
|
|
1415
|
+
</attribute>
|
|
1416
|
+
<optional>
|
|
1417
|
+
<attribute name="text">
|
|
1418
|
+
<a:documentation>An optional textual description of the date, especially when a Gregorian date is not applicable</a:documentation>
|
|
1419
|
+
</attribute>
|
|
1420
|
+
</optional>
|
|
1421
|
+
</define>
|
|
1419
1422
|
<define name="docidentifier">
|
|
1420
1423
|
<a:documentation>An identifier of a bibliographic item in an international standard scheme</a:documentation>
|
|
1421
1424
|
<element name="docidentifier">
|
|
@@ -1884,6 +1887,10 @@ Detailed in https://www.relaton.org/model/relations/</a:documentation>
|
|
|
1884
1887
|
<value>hasAnnotation</value>
|
|
1885
1888
|
<value>draftOf</value>
|
|
1886
1889
|
<value>hasDraft</value>
|
|
1890
|
+
<value>preliminaryDraftOf</value>
|
|
1891
|
+
<value>hasPreliminaryDraft</value>
|
|
1892
|
+
<value>revisionDraftOf</value>
|
|
1893
|
+
<value>hasRevisionDraft</value>
|
|
1887
1894
|
<value>editionOf</value>
|
|
1888
1895
|
<value>hasEdition</value>
|
|
1889
1896
|
<value>updates</value>
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
module Metanorma
|
|
2
|
-
module
|
|
2
|
+
module Iso
|
|
3
3
|
class Converter < Standoc::Converter
|
|
4
|
-
def id_prefix(prefix, id)
|
|
4
|
+
def id_prefix(prefix, id, amd: false)
|
|
5
5
|
# we're just inheriting the prefixes from parent doc
|
|
6
|
-
|
|
6
|
+
amd and return id.text
|
|
7
7
|
prefix.join("/") + (id.text.match?(%{^/}) ? "" : " ") + id.text
|
|
8
8
|
end
|
|
9
9
|
|
|
@@ -16,10 +16,12 @@ module Metanorma
|
|
|
16
16
|
end
|
|
17
17
|
|
|
18
18
|
# ISO as a prefix goes first
|
|
19
|
-
def docidentifier_cleanup(
|
|
20
|
-
prefix = get_id_prefix(
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
def docidentifier_cleanup(xml)
|
|
20
|
+
prefix = get_id_prefix(xml)
|
|
21
|
+
amd = @amd || xml.at("//bibdata/ext/doctype")&.text == "addendum"
|
|
22
|
+
id = xml.at("//bibdata/ext/structuredidentifier/project-number") and
|
|
23
|
+
id.content =
|
|
24
|
+
id_prefix(prefix, id, amd:)
|
|
23
25
|
end
|
|
24
26
|
|
|
25
27
|
def format_ref(ref, type)
|
|
@@ -8,7 +8,7 @@ require "metanorma/iso/validate"
|
|
|
8
8
|
require "metanorma/iso/cleanup"
|
|
9
9
|
|
|
10
10
|
module Metanorma
|
|
11
|
-
module
|
|
11
|
+
module Iso
|
|
12
12
|
# A {Converter} implementation that generates ISO output, and a document
|
|
13
13
|
# schema encapsulation of the document for validation
|
|
14
14
|
class Converter < ::Metanorma::Standoc::Converter
|
data/lib/metanorma/iso/front.rb
CHANGED
|
@@ -8,7 +8,7 @@ require_relative "front_id"
|
|
|
8
8
|
require_relative "front_contributor"
|
|
9
9
|
|
|
10
10
|
module Metanorma
|
|
11
|
-
module
|
|
11
|
+
module Iso
|
|
12
12
|
class Converter < Standoc::Converter
|
|
13
13
|
def metadata_ext(node, xml)
|
|
14
14
|
super
|
|
@@ -47,7 +47,7 @@ module Metanorma
|
|
|
47
47
|
end
|
|
48
48
|
end
|
|
49
49
|
|
|
50
|
-
def
|
|
50
|
+
def metadata_flavor(node, xml)
|
|
51
51
|
super
|
|
52
52
|
a = node.attr("horizontal") and xml.horizontal a
|
|
53
53
|
end
|
|
@@ -71,10 +71,9 @@ module Metanorma
|
|
|
71
71
|
end
|
|
72
72
|
|
|
73
73
|
def title_intro(node, xml, lang, at)
|
|
74
|
-
|
|
75
|
-
|
|
74
|
+
t = node.attr("title-intro-#{lang}") or return
|
|
76
75
|
xml.title(**attr_code(at.merge(type: "title-intro"))) do |t1|
|
|
77
|
-
t1 << Metanorma::Utils::asciidoc_sub(
|
|
76
|
+
t1 << Metanorma::Utils::asciidoc_sub(t)
|
|
78
77
|
end
|
|
79
78
|
end
|
|
80
79
|
|
|
@@ -85,20 +84,23 @@ module Metanorma
|
|
|
85
84
|
end
|
|
86
85
|
|
|
87
86
|
def title_part(node, xml, lang, at)
|
|
88
|
-
|
|
89
|
-
|
|
87
|
+
t = node.attr("title-part-#{lang}") or return
|
|
90
88
|
xml.title(**attr_code(at.merge(type: "title-part"))) do |t1|
|
|
91
|
-
t1 << Metanorma::Utils::asciidoc_sub(
|
|
89
|
+
t1 << Metanorma::Utils::asciidoc_sub(t)
|
|
92
90
|
end
|
|
93
91
|
end
|
|
94
92
|
|
|
95
93
|
def title_amd(node, xml, lang, at)
|
|
96
|
-
|
|
97
|
-
|
|
94
|
+
t = node.attr("title-amendment-#{lang}") or return
|
|
98
95
|
xml.title(**attr_code(at.merge(type: "title-amd"))) do |t1|
|
|
99
|
-
t1 << Metanorma::Utils::asciidoc_sub(
|
|
100
|
-
|
|
101
|
-
|
|
96
|
+
t1 << Metanorma::Utils::asciidoc_sub(t)
|
|
97
|
+
end
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
def title_add(node, xml, lang, at)
|
|
101
|
+
t = node.attr("title-addendum-#{lang}") or return
|
|
102
|
+
xml.title(**attr_code(at.merge(type: "title-add"))) do |t1|
|
|
103
|
+
t1 << Metanorma::Utils::asciidoc_sub(t)
|
|
102
104
|
end
|
|
103
105
|
end
|
|
104
106
|
|
|
@@ -107,9 +109,11 @@ module Metanorma
|
|
|
107
109
|
intro = node.attr("title-intro-#{lang}")
|
|
108
110
|
part = node.attr("title-part-#{lang}")
|
|
109
111
|
amd = node.attr("title-amendment-#{lang}")
|
|
112
|
+
add = node.attr("title-addendum-#{lang}")
|
|
110
113
|
title = "#{intro} -- #{title}" if intro
|
|
111
114
|
title = "#{title} -- #{part}" if part
|
|
112
115
|
title = "#{title} -- #{amd}" if amd && @amd
|
|
116
|
+
title = "#{title} -- #{add}" if amd && node.attr("addendum-number")
|
|
113
117
|
xml.title **attr_code(at.merge(type: "main")) do |t1|
|
|
114
118
|
t1 << Metanorma::Utils::asciidoc_sub(title)
|
|
115
119
|
end
|
|
@@ -123,12 +127,13 @@ module Metanorma
|
|
|
123
127
|
title_main(node, xml, lang, at)
|
|
124
128
|
title_part(node, xml, lang, at)
|
|
125
129
|
title_amd(node, xml, lang, at) if @amd
|
|
130
|
+
title_add(node, xml, lang, at) if node.attr("addendum-number")
|
|
126
131
|
end
|
|
127
132
|
end
|
|
128
133
|
|
|
129
134
|
def relaton_relations
|
|
130
135
|
super + %w(obsoletes successor-of manifestation-of related
|
|
131
|
-
annotation-of)
|
|
136
|
+
annotation-of has-draft)
|
|
132
137
|
end
|
|
133
138
|
|
|
134
139
|
def relaton_relation_descriptions
|
|
@@ -5,7 +5,7 @@ require "pubid-cen"
|
|
|
5
5
|
require "pubid-iec"
|
|
6
6
|
|
|
7
7
|
module Metanorma
|
|
8
|
-
module
|
|
8
|
+
module Iso
|
|
9
9
|
class Converter < Standoc::Converter
|
|
10
10
|
def metadata_id(node, xml)
|
|
11
11
|
if id = node.attr("docidentifier")
|
|
@@ -27,6 +27,7 @@ module Metanorma
|
|
|
27
27
|
# document's type, eg. :tr, :ts, :amd, :cor, Type.new(:tr)
|
|
28
28
|
def get_typeabbr(node, amd: false)
|
|
29
29
|
node.attr("amendment-number") and return :amd
|
|
30
|
+
node.attr("addendum-number") and return :add
|
|
30
31
|
node.attr("corrigendum-number") and return :cor
|
|
31
32
|
DOCTYPE2HASHID[doctype(node).to_sym]
|
|
32
33
|
end
|
|
@@ -100,7 +101,8 @@ module Metanorma
|
|
|
100
101
|
def iso_id_params_add(node)
|
|
101
102
|
stage = iso_id_stage(node)
|
|
102
103
|
ret = { number: node.attr("amendment-number") ||
|
|
103
|
-
node.attr("corrigendum-number")
|
|
104
|
+
node.attr("corrigendum-number") ||
|
|
105
|
+
node.attr("addendum-number"),
|
|
104
106
|
year: iso_id_year(node),
|
|
105
107
|
iteration: node.attr("iteration") }
|
|
106
108
|
iso_id_stage_populate(ret, node, stage)
|
|
@@ -139,7 +141,8 @@ module Metanorma
|
|
|
139
141
|
|
|
140
142
|
def iso_id_params_resolve(params, params2, node, orig_id)
|
|
141
143
|
if orig_id && (node.attr("amendment-number") ||
|
|
142
|
-
node.attr("corrigendum-number")
|
|
144
|
+
node.attr("corrigendum-number") ||
|
|
145
|
+
node.attr("addendum-number"))
|
|
143
146
|
%i(unpublished part).each { |x| params.delete(x) }
|
|
144
147
|
params2[:base] = orig_id
|
|
145
148
|
elsif orig_id &&
|
|
@@ -221,6 +224,7 @@ module Metanorma
|
|
|
221
224
|
part:, subpart:,
|
|
222
225
|
amendment: node.attr("amendment-number"),
|
|
223
226
|
corrigendum: node.attr("corrigendum-number"),
|
|
227
|
+
addendum: node.attr("addendum-number"),
|
|
224
228
|
origyr: node.attr("created-date")
|
|
225
229
|
))
|
|
226
230
|
end
|
|
@@ -3,7 +3,6 @@ require "metanorma/processor"
|
|
|
3
3
|
module Metanorma
|
|
4
4
|
module Iso
|
|
5
5
|
class Processor < Metanorma::Processor
|
|
6
|
-
|
|
7
6
|
def initialize # rubocop:disable Lint/MissingSuper
|
|
8
7
|
@short = :iso
|
|
9
8
|
@input_format = :asciidoc
|
|
@@ -22,7 +21,7 @@ module Metanorma
|
|
|
22
21
|
end
|
|
23
22
|
|
|
24
23
|
def version
|
|
25
|
-
"Metanorma::
|
|
24
|
+
"Metanorma::Iso #{Metanorma::Iso::VERSION}"
|
|
26
25
|
end
|
|
27
26
|
|
|
28
27
|
def fonts_manifest
|
|
@@ -38,12 +37,12 @@ module Metanorma
|
|
|
38
37
|
end
|
|
39
38
|
|
|
40
39
|
def use_presentation_xml(ext)
|
|
41
|
-
return true if [
|
|
40
|
+
return true if %i[html_alt sts isosts].include?(ext)
|
|
42
41
|
|
|
43
42
|
super
|
|
44
43
|
end
|
|
45
44
|
|
|
46
|
-
def output(isodoc_node, inname, outname, format, options={})
|
|
45
|
+
def output(isodoc_node, inname, outname, format, options = {})
|
|
47
46
|
options_preprocess(options)
|
|
48
47
|
case format
|
|
49
48
|
when :html
|
|
@@ -71,7 +70,6 @@ module Metanorma
|
|
|
71
70
|
super
|
|
72
71
|
end
|
|
73
72
|
end
|
|
74
|
-
|
|
75
73
|
end
|
|
76
74
|
end
|
|
77
75
|
end
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
<optional>
|
|
10
10
|
<ref name="docsubtype"/>
|
|
11
11
|
</optional>
|
|
12
|
+
<ref name="flavor"/>
|
|
12
13
|
<optional>
|
|
13
14
|
<ref name="horizontal"/>
|
|
14
15
|
</optional>
|
|
@@ -103,6 +104,7 @@
|
|
|
103
104
|
<value>technical-corrigendum</value>
|
|
104
105
|
<value>directive</value>
|
|
105
106
|
<value>committee-document</value>
|
|
107
|
+
<value>addendum</value>
|
|
106
108
|
</choice>
|
|
107
109
|
</define>
|
|
108
110
|
<define name="DocumentSubtype">
|
|
@@ -10,7 +10,7 @@ require "jing"
|
|
|
10
10
|
require "iev"
|
|
11
11
|
|
|
12
12
|
module Metanorma
|
|
13
|
-
module
|
|
13
|
+
module Iso
|
|
14
14
|
class Converter < Standoc::Converter
|
|
15
15
|
def isosubgroup_validate(root)
|
|
16
16
|
root.xpath("//technical-committee/@type").each do |t|
|
|
@@ -139,7 +139,8 @@ module Metanorma
|
|
|
139
139
|
def doctype_validate(_xmldoc)
|
|
140
140
|
%w(international-standard technical-specification technical-report
|
|
141
141
|
publicly-available-specification international-workshop-agreement
|
|
142
|
-
guide amendment technical-corrigendum committee-document
|
|
142
|
+
guide amendment technical-corrigendum committee-document addendum
|
|
143
|
+
recommendation)
|
|
143
144
|
.include? @doctype or
|
|
144
145
|
@log.add("Document Attributes", nil,
|
|
145
146
|
"#{@doctype} is not a recognised document type")
|
data/metanorma-iso.gemspec
CHANGED
|
@@ -6,7 +6,7 @@ require "metanorma/iso/version"
|
|
|
6
6
|
|
|
7
7
|
Gem::Specification.new do |spec|
|
|
8
8
|
spec.name = "metanorma-iso"
|
|
9
|
-
spec.version = Metanorma::
|
|
9
|
+
spec.version = Metanorma::Iso::VERSION
|
|
10
10
|
spec.authors = ["Ribose Inc."]
|
|
11
11
|
spec.email = ["open.source@ribose.com"]
|
|
12
12
|
|
|
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
|
|
|
29
29
|
f.match(%r{^(test|spec|features|bin|.github)/}) \
|
|
30
30
|
|| f.match(%r{Rakefile|bin/rspec})
|
|
31
31
|
end
|
|
32
|
-
spec.test_files
|
|
32
|
+
spec.test_files = `git ls-files -- {spec}/*`.split("\n")
|
|
33
33
|
spec.required_ruby_version = Gem::Requirement.new(">= 3.1.0")
|
|
34
34
|
|
|
35
35
|
spec.add_dependency "metanorma-standoc", "~> 2.9.3"
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: metanorma-iso
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.8.
|
|
4
|
+
version: 2.8.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ribose Inc.
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2024-
|
|
11
|
+
date: 2024-10-14 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: metanorma-standoc
|