pubid-iso 0.1.9 → 0.1.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pubid/iso/parser.rb +5 -7
- data/lib/pubid/iso/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eb49fb09056ae2a808d1fef9f8c1bd107285095fdf3496fad1a2bc9b929d3555
|
4
|
+
data.tar.gz: dfe7c869035871233c2d318bc2eb3b9baa98208cc29ac7e59ac538402850a91a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af2a0127f4cebfa368c26b6e55b651c70dce70d25af68d9d6af8e0e1f56487ec7a73dbadc0abb423d6bb4da26d013754ae7b65e38d897ab8cd79a4c0250fa3f4
|
7
|
+
data.tar.gz: 0afe6817acab2cf6f32164669038e1ab96cbd34763921191f43d8e96606bac0355f000c825b01799ff70aeca8bb1f8539d4a7a5f5b057c4259dec23bc25f07b2
|
data/lib/pubid/iso/parser.rb
CHANGED
@@ -71,20 +71,18 @@ module Pubid::Iso
|
|
71
71
|
((str("/") >> stage.as(:stage)).maybe >>
|
72
72
|
(str("/") | space).maybe >>
|
73
73
|
(str("Amd") | str("AMD") | str("AM")) >>
|
74
|
-
str(".").maybe >>
|
75
|
-
space.maybe >>
|
74
|
+
(space | str(".")).repeat(1).maybe >>
|
76
75
|
digits.as(:version) >>
|
77
|
-
(str(":") >> digits.as(:number)).maybe).as(:amendments)
|
76
|
+
((str(":") | str("-")) >> digits.as(:number)).maybe).as(:amendments)
|
78
77
|
end
|
79
78
|
|
80
79
|
rule(:corrigendum) do
|
81
80
|
((str("/") >> stage.as(:stage)).maybe >>
|
82
81
|
(str("/") | space).maybe >>
|
83
82
|
(str("Cor") | str("COR")) >>
|
84
|
-
str(".").maybe >>
|
85
|
-
space.maybe >>
|
83
|
+
(space | str(".")).repeat(1).maybe >>
|
86
84
|
digits.as(:version) >>
|
87
|
-
(str(":") >> digits.as(:number)).maybe).as(:corrigendums)
|
85
|
+
((str(":") | str("-")) >> digits.as(:number)).maybe).as(:corrigendums)
|
88
86
|
end
|
89
87
|
|
90
88
|
rule(:language) do
|
@@ -133,7 +131,7 @@ module Pubid::Iso
|
|
133
131
|
# for identifiers like ISO 5537/IDF 26
|
134
132
|
(str("|") >> (str("IDF") >> space >> digits).as(:joint_document)).maybe >>
|
135
133
|
part.maybe >> iteration.maybe >>
|
136
|
-
(space? >> str(":") >> year).maybe >>
|
134
|
+
(space? >> (str(":") | str("-")) >> year).maybe >>
|
137
135
|
# stage before amendment
|
138
136
|
(
|
139
137
|
# stage before corrigendum
|
data/lib/pubid/iso/version.rb
CHANGED