metanorma-iso 2.7.2 → 2.7.4
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/init.rb +5 -0
- data/lib/isodoc/iso/iso.amendment.xsl +879 -188
- data/lib/isodoc/iso/iso.international-standard.xsl +879 -188
- data/lib/isodoc/iso/presentation_xml_convert.rb +0 -5
- data/lib/metanorma/iso/base.rb +0 -8
- data/lib/metanorma/iso/biblio.rng +28 -25
- data/lib/metanorma/iso/boilerplate-fr.adoc +35 -1
- data/lib/metanorma/iso/boilerplate-ru.adoc +36 -1
- data/lib/metanorma/iso/boilerplate.adoc +34 -1
- data/lib/metanorma/iso/front_id.rb +9 -14
- data/lib/metanorma/iso/relaton-iso.rng +1 -0
- data/lib/metanorma/iso/validate.rb +1 -1
- data/lib/metanorma/iso/version.rb +1 -1
- data/metanorma-iso.gemspec +1 -1
- metadata +4 -4
@@ -120,11 +120,6 @@ module IsoDoc
|
|
120
120
|
"#{xml} — "
|
121
121
|
end
|
122
122
|
|
123
|
-
def bibrenderer
|
124
|
-
::Relaton::Render::Iso::General.new(language: @lang,
|
125
|
-
i18nhash: @i18n.get)
|
126
|
-
end
|
127
|
-
|
128
123
|
def bibrender_formattedref(formattedref, xml)
|
129
124
|
%w(techreport standard).include? xml["type"] and return
|
130
125
|
super
|
data/lib/metanorma/iso/base.rb
CHANGED
@@ -83,14 +83,6 @@ module Metanorma
|
|
83
83
|
node.attr("document-scheme") || "2024"
|
84
84
|
end
|
85
85
|
|
86
|
-
def metadata_attrs(node)
|
87
|
-
ret = super
|
88
|
-
a = document_scheme(node) and
|
89
|
-
ret += "<presentation-metadata><name>document-scheme</name>" \
|
90
|
-
"<value>#{a}</value></presentation-metadata>"
|
91
|
-
ret
|
92
|
-
end
|
93
|
-
|
94
86
|
def outputs(node, ret)
|
95
87
|
File.open("#{@filename}.xml", "w:UTF-8") { |f| f.write(ret) }
|
96
88
|
presentation_xml_converter(node).convert("#{@filename}.xml")
|
@@ -338,29 +338,32 @@
|
|
338
338
|
</define>
|
339
339
|
<define name="organization">
|
340
340
|
<element name="organization">
|
341
|
-
<
|
342
|
-
<ref name="orgname"/>
|
343
|
-
</oneOrMore>
|
344
|
-
<zeroOrMore>
|
345
|
-
<ref name="subdivision"/>
|
346
|
-
</zeroOrMore>
|
347
|
-
<optional>
|
348
|
-
<ref name="abbreviation"/>
|
349
|
-
</optional>
|
350
|
-
<zeroOrMore>
|
351
|
-
<ref name="uri"/>
|
352
|
-
</zeroOrMore>
|
353
|
-
<zeroOrMore>
|
354
|
-
<ref name="org-identifier"/>
|
355
|
-
</zeroOrMore>
|
356
|
-
<zeroOrMore>
|
357
|
-
<ref name="contact"/>
|
358
|
-
</zeroOrMore>
|
359
|
-
<optional>
|
360
|
-
<ref name="logo"/>
|
361
|
-
</optional>
|
341
|
+
<ref name="OrganizationType"/>
|
362
342
|
</element>
|
363
343
|
</define>
|
344
|
+
<define name="OrganizationType">
|
345
|
+
<oneOrMore>
|
346
|
+
<ref name="orgname"/>
|
347
|
+
</oneOrMore>
|
348
|
+
<zeroOrMore>
|
349
|
+
<ref name="subdivision"/>
|
350
|
+
</zeroOrMore>
|
351
|
+
<optional>
|
352
|
+
<ref name="abbreviation"/>
|
353
|
+
</optional>
|
354
|
+
<zeroOrMore>
|
355
|
+
<ref name="uri"/>
|
356
|
+
</zeroOrMore>
|
357
|
+
<zeroOrMore>
|
358
|
+
<ref name="org-identifier"/>
|
359
|
+
</zeroOrMore>
|
360
|
+
<zeroOrMore>
|
361
|
+
<ref name="contact"/>
|
362
|
+
</zeroOrMore>
|
363
|
+
<optional>
|
364
|
+
<ref name="logo"/>
|
365
|
+
</optional>
|
366
|
+
</define>
|
364
367
|
<define name="orgname">
|
365
368
|
<element name="name">
|
366
369
|
<choice>
|
@@ -371,10 +374,10 @@
|
|
371
374
|
</define>
|
372
375
|
<define name="subdivision">
|
373
376
|
<element name="subdivision">
|
374
|
-
<
|
375
|
-
<
|
376
|
-
|
377
|
-
|
377
|
+
<optional>
|
378
|
+
<attribute name="type"/>
|
379
|
+
</optional>
|
380
|
+
<ref name="OrganizationType"/>
|
378
381
|
</element>
|
379
382
|
</define>
|
380
383
|
<define name="logo">
|
@@ -18,11 +18,45 @@ Imprimé en Suisse
|
|
18
18
|
Ce document est également édité en anglais et en russe. Il peut être obtenu auprès des organisations +
|
19
19
|
nationales de normalisation.
|
20
20
|
|
21
|
+
{% elsif document_scheme == "1972" or document_scheme == "1987" %}
|
22
|
+
|
23
|
+
=== {blank}
|
24
|
+
|
25
|
+
[[boilerplate-year]]
|
26
|
+
©   span:std_publisher[*Organisation Nationale de Normalisation*], span:date[*{{ docyear }}*]   ●
|
27
|
+
|
28
|
+
[[boilerplate-place]]
|
29
|
+
Publié en Suisse
|
30
|
+
|
31
|
+
|
32
|
+
{% elsif document_scheme == "1989" %}
|
33
|
+
|
34
|
+
=== {blank}
|
35
|
+
|
36
|
+
[[boilerplate-year]]
|
37
|
+
© span:std_publisher[{{ agency }} ]span:date[{{ docyear }}]
|
38
|
+
|
39
|
+
[[boilerplate-message]]
|
40
|
+
Droits de reproduction réservés. Sauf prescription différente, aucune partie de cette publication
|
41
|
+
ne peut être reproduite ni utilisée sous quelque forme que ce soit et par aucun procédé,
|
42
|
+
électronique ou mécanique, y compris la photocopie et les microfilms, sans l'accord écrit de l'éditeur.
|
43
|
+
|
44
|
+
[[boilerplate-address]]
|
45
|
+
[align=left]
|
46
|
+
Organisation internationale de normalisation +
|
47
|
+
Case postale 56 • CH-1211 Genève 20 • Suisse +
|
48
|
+
Internet   central@iso.ch +
|
49
|
+
X.400      c=ch; a=400net; p=iso; o=isocs; s=central
|
50
|
+
|
51
|
+
[[boilerplate-place]]
|
52
|
+
Imprimé en Suisse
|
53
|
+
|
54
|
+
|
21
55
|
{% else %}
|
22
56
|
=== {% if stage_int >= 40 %}DOCUMENT PROTÉGÉ PAR COPYRIGHT{%else%}{blank}{%endif%}
|
23
57
|
|
24
58
|
[[boilerplate-year]]
|
25
|
-
© span:std_publisher:[{{ agency }} ]span:
|
59
|
+
© span:std_publisher:[{{ agency }} ]span:date[{{ docyear }}]
|
26
60
|
|
27
61
|
[[boilerplate-message]]
|
28
62
|
Droits de reproduction réservés. Sauf indication contraire, ou requise dans le cadre de sa mise en œuvre,
|
@@ -1,9 +1,43 @@
|
|
1
1
|
== copyright-statement
|
2
2
|
|
3
|
+
{% if document_scheme == "1972" or document_scheme == "1987" %}
|
4
|
+
|
5
|
+
=== {blank}
|
6
|
+
|
7
|
+
[[boilerplate-year]]
|
8
|
+
©   span:std_publisher[*Международная Организация по Стандартизации*], span:date[*{{ docyear }}*]   ●
|
9
|
+
|
10
|
+
[[boilerplate-place]]
|
11
|
+
Издано в Швейцарии
|
12
|
+
|
13
|
+
{% elsif document_scheme == "1989" %}
|
14
|
+
|
15
|
+
=== {blank}
|
16
|
+
|
17
|
+
[[boilerplate-year]]
|
18
|
+
© span:std_publisher[{{ agency }} ]span:date[{{ docyear }}]
|
19
|
+
|
20
|
+
[[boilerplate-message]]
|
21
|
+
Охраняется авторским правом. Если это особо не указано, то никакая часть данной публикации не может быть воспроизведена и
|
22
|
+
использована в любой форме или любыми средствами, электронными или механическими, включая фотокопирование и
|
23
|
+
микрофильмирование, без предварительного письменного разрешения издателя.
|
24
|
+
|
25
|
+
[[boilerplate-address]]
|
26
|
+
[align=left]
|
27
|
+
Международная Организация по Стандартизации +
|
28
|
+
Почтовый адрес: 56 • CH-1211 Geneva 20 • Switzerland +
|
29
|
+
Адрес в Интернете: central@iso.ch +
|
30
|
+
X.400          c=ch; a=400net; p=iso; o=isocs; s=central
|
31
|
+
|
32
|
+
[[boilerplate-place]]
|
33
|
+
Напечатано в Швейцарии
|
34
|
+
|
35
|
+
{% else %}
|
36
|
+
|
3
37
|
=== {% if stage_int >= 40 %}ДОКУМЕНТ, ОХРАНЯЕМЫЙ АВТОРСКИМ ПРАВОМ{% else %}{blank}{% endif %}
|
4
38
|
|
5
39
|
[[boilerplate-year]]
|
6
|
-
© span:std_publisher[{{ agency }} ]span:
|
40
|
+
© span:std_publisher[{{ agency }} ]span:date[{{ docyear }}]
|
7
41
|
|
8
42
|
[[boilerplate-message]]
|
9
43
|
Все права защищены. Если иначе не определено или не требуется в контексте его реализации, никакая часть этой публикации не может быть воспроизведена или использована иначе в любой форме или каким-либо образом, электронным или механическим, включая фотокопирование, или публикацию в Интернете или интранете, без предварительного письменного разрешения. Разрешение может быть запрошено ISO по адресу, указанному ниже, или у органа — члена ISO страны запрашивающего.
|
@@ -28,3 +62,4 @@ CH-1214 Vernier, Geneva +
|
|
28
62
|
|
29
63
|
Получателям этого проекта предлагается представить вместе со своими комментариями уведомление о любых соответствующих патентных правах, о которых им известно, и предоставить подтверждающую документацию.
|
30
64
|
{% endif %}
|
65
|
+
{% endif %}
|
@@ -18,12 +18,45 @@ Printed in Switzerland
|
|
18
18
|
|
19
19
|
Also issued in French and Russian. Copies to be obtained through the national standards organizations.
|
20
20
|
|
21
|
+
{% elsif document_scheme == "1972" or document_scheme == "1987" %}
|
22
|
+
|
23
|
+
=== {blank}
|
24
|
+
|
25
|
+
[[boilerplate-year]]
|
26
|
+
©   span:std_publisher[*International Organization for Standardization*], span:date[*{{ docyear }}*]   ●
|
27
|
+
|
28
|
+
[[boilerplate-place]]
|
29
|
+
Printed in Switzerland
|
30
|
+
|
31
|
+
|
32
|
+
{% elsif document_scheme == "1989" %}
|
33
|
+
|
34
|
+
=== {blank}
|
35
|
+
|
36
|
+
[[boilerplate-year]]
|
37
|
+
© span:std_publisher[{{ agency }} ]span:date[{{ docyear }}]
|
38
|
+
|
39
|
+
[[boilerplate-message]]
|
40
|
+
All rights reserved. Unless otherwise specified, no part of this publication may be reproduced
|
41
|
+
or utilized in any form or by any means, electronic or mechanical, including photocopying and
|
42
|
+
microfilm, without permission in writing from the publisher.
|
43
|
+
|
44
|
+
[[boilerplate-address]]
|
45
|
+
[align=left]
|
46
|
+
International Organization for Standardization +
|
47
|
+
Case postale 56 • CH-1211 Genève 20 • Switzerland +
|
48
|
+
Internet   central@iso.ch +
|
49
|
+
X.400     c=ch; a=400net; p=iso; o=isocs; s=central
|
50
|
+
|
51
|
+
[[boilerplate-place]]
|
52
|
+
Printed in Switzerland
|
53
|
+
|
21
54
|
{% else %}
|
22
55
|
|
23
56
|
=== {% if stage_int >= 40 %}COPYRIGHT PROTECTED DOCUMENT{% else %}{blank}{% endif %}
|
24
57
|
|
25
58
|
[[boilerplate-year]]
|
26
|
-
© span:std_publisher[{{ agency }} ]span:
|
59
|
+
© span:std_publisher[{{ agency }} ]span:date[{{ docyear }}]
|
27
60
|
|
28
61
|
[[boilerplate-message]]
|
29
62
|
All rights reserved. Unless otherwise specified, or required in the context of its implementation,
|
@@ -1,5 +1,4 @@
|
|
1
1
|
require "date"
|
2
|
-
require "pathname"
|
3
2
|
require "twitter_cldr"
|
4
3
|
require "pubid-iso"
|
5
4
|
require "pubid-cen"
|
@@ -22,7 +21,7 @@ module Metanorma
|
|
22
21
|
{ directive: :dir, "technical-report": :tr, "guide": :guide,
|
23
22
|
"technical-specification": :ts,
|
24
23
|
"publicly-available-specification": :pas,
|
25
|
-
"committee-document": :tc }.freeze
|
24
|
+
"committee-document": :tc, "recommendation": :r }.freeze
|
26
25
|
|
27
26
|
# @param type [nil, :tr, :ts, :amd, :cor, :guide, :dir, :tc, Type]
|
28
27
|
# document's type, eg. :tr, :ts, :amd, :cor, Type.new(:tr)
|
@@ -111,12 +110,12 @@ module Metanorma
|
|
111
110
|
|
112
111
|
def tc_number(ret, node)
|
113
112
|
doctype(node) == "committee-document" or return ret
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
113
|
+
{ sc: "subcommittee", tc: "technical-committee",
|
114
|
+
wg: "workgroup" }.each do |k, v|
|
115
|
+
n = node.attr("#{v}-number") and
|
116
|
+
ret.merge!({ "#{k}type": node.attr("#{v}-type") || k.to_s.upcase,
|
117
|
+
"#{k}number": n })
|
118
|
+
end
|
120
119
|
ret
|
121
120
|
end
|
122
121
|
|
@@ -185,9 +184,7 @@ module Metanorma
|
|
185
184
|
def iso_id_default(params)
|
186
185
|
params_nolang = params.dup.tap { |hs| hs.delete(:language) }
|
187
186
|
params1 = if params[:unpublished]
|
188
|
-
params_nolang.dup.tap
|
189
|
-
hs.delete(:year)
|
190
|
-
end
|
187
|
+
params_nolang.dup.tap { |hs| hs.delete(:year) }
|
191
188
|
else params_nolang
|
192
189
|
end
|
193
190
|
params1.delete(:unpublished)
|
@@ -205,9 +202,7 @@ module Metanorma
|
|
205
202
|
|
206
203
|
def iso_id_with_lang(params)
|
207
204
|
params1 = if params[:unpublished]
|
208
|
-
params.dup.tap
|
209
|
-
hs.delete(:year)
|
210
|
-
end
|
205
|
+
params.dup.tap { |hs| hs.delete(:year) }
|
211
206
|
else params end
|
212
207
|
params1.delete(:unpublished)
|
213
208
|
pubid_select(params1).create(**params1)
|
@@ -98,6 +98,7 @@
|
|
98
98
|
<value>publicly-available-specification</value>
|
99
99
|
<value>international-workshop-agreement</value>
|
100
100
|
<value>guide</value>
|
101
|
+
<value>recommendation</value>
|
101
102
|
<value>amendment</value>
|
102
103
|
<value>technical-corrigendum</value>
|
103
104
|
<value>directive</value>
|
@@ -119,7 +119,7 @@ module Metanorma
|
|
119
119
|
def doctype_validate(_xmldoc)
|
120
120
|
%w(international-standard technical-specification technical-report
|
121
121
|
publicly-available-specification international-workshop-agreement
|
122
|
-
guide amendment technical-corrigendum committee-document)
|
122
|
+
guide amendment technical-corrigendum committee-document recommendation)
|
123
123
|
.include? @doctype or
|
124
124
|
@log.add("Document Attributes", nil,
|
125
125
|
"#{@doctype} is not a recognised document type")
|
data/metanorma-iso.gemspec
CHANGED
@@ -32,7 +32,7 @@ Gem::Specification.new do |spec|
|
|
32
32
|
spec.test_files = `git ls-files -- {spec}/*`.split("\n")
|
33
33
|
spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
|
34
34
|
|
35
|
-
spec.add_dependency "metanorma-standoc", "~> 2.8.
|
35
|
+
spec.add_dependency "metanorma-standoc", "~> 2.8.4"
|
36
36
|
spec.add_dependency "mnconvert", "~> 1.14"
|
37
37
|
spec.add_dependency "pubid-cen"
|
38
38
|
spec.add_dependency "pubid-iec"
|
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.7.
|
4
|
+
version: 2.7.4
|
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-03-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-standoc
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.8.
|
19
|
+
version: 2.8.4
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.8.
|
26
|
+
version: 2.8.4
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: mnconvert
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|