extended_yaml 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/extended_yaml/version.rb +1 -1
- data/lib/extended_yaml.rb +9 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d4ee11f47e33513fd8398d47f605460d2730beea6420340a906d6bf802f35996
|
4
|
+
data.tar.gz: f9e6c2fd5ff1150a9694e871f79d2471680f18d2240eb9df21caf81e0687495f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1058232576e3c99969dede0083812f3dc566ccf5c9a6d7e293ccc99bc06f4a026cba2d531c79efec16b05e6bee13b85c0b261c10a409968b3d1e893b7d26978d
|
7
|
+
data.tar.gz: b621f31a3c9a4895a2aa1c6cbd823e803a364dffa0113f6329c35b7590f14f373cbad893663fcb37b23c4560c83f18641ec23f65560c31de06d042e1ce95ae38
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@ Extended YAML
|
|
2
2
|
==================================================
|
3
3
|
|
4
4
|
[![Gem Version](https://badge.fury.io/rb/extended_yaml.svg)](https://badge.fury.io/rb/extended_yaml)
|
5
|
-
[![Build Status](https://
|
5
|
+
[![Build Status](https://github.com/DannyBen/extended_yaml/workflows/Test/badge.svg)](https://github.com/DannyBen/extended_yaml/actions?query=workflow%3ATest)
|
6
6
|
[![Maintainability](https://api.codeclimate.com/v1/badges/0d162ff84c50abe7c83a/maintainability)](https://codeclimate.com/github/DannyBen/extended_yaml/maintainability)
|
7
7
|
|
8
8
|
---
|
data/lib/extended_yaml.rb
CHANGED
@@ -19,7 +19,14 @@ class ExtendedYAML
|
|
19
19
|
|
20
20
|
# @return [Hash, Array, nil] the parsed YAML
|
21
21
|
def result
|
22
|
-
|
22
|
+
# ref: https://bugs.ruby-lang.org/issues/17866
|
23
|
+
begin
|
24
|
+
data = ::YAML.load evaluate, aliases: true
|
25
|
+
rescue ArgumentError
|
26
|
+
# :nocov:
|
27
|
+
data = ::YAML.load evaluate
|
28
|
+
# :nocov:
|
29
|
+
end
|
23
30
|
data ? resolve_extends(data) : nil
|
24
31
|
end
|
25
32
|
|
@@ -77,6 +84,6 @@ private
|
|
77
84
|
def expand_path(path)
|
78
85
|
path += extension unless path.end_with? extension
|
79
86
|
path = File.expand_path path, base_dir
|
80
|
-
path.include?('*') ? Dir[path] : [path]
|
87
|
+
path.include?('*') ? Dir[path].sort : [path]
|
81
88
|
end
|
82
89
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: extended_yaml
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Danny Ben Shitrit
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-02-20 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Load YAML files that deep merge other YAML files
|
14
14
|
email: db@dannyben.com
|
@@ -39,7 +39,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
requirements: []
|
42
|
-
rubygems_version: 3.
|
42
|
+
rubygems_version: 3.2.15
|
43
43
|
signing_key:
|
44
44
|
specification_version: 4
|
45
45
|
summary: Load YAML files that merge other YAML files
|