ravioli 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ravioli/builder.rb +4 -5
- data/lib/ravioli/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 319a36e063b7926065d63a7bad7284f2e997ecc161000cea2a0583c8fb5a68ce
|
4
|
+
data.tar.gz: cc085fc7660369588072aa59abd5aacfb4658ca2438c2f1544d26436bb17dcc0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a4c13002dc24f8faab15a1d3d329bd626b93e8c2290744a01f5da7fd8fc71e2ebc1fa835886418070014603295c31f722dc8e88d6ead711115f18edbf1a6e373
|
7
|
+
data.tar.gz: 7cdf9515b01290c85f61ea7292daf7a63c8b870736455d2ffe0eba7e4f5749ecd1bdf331ac40206afa735a5cea774e8028f0b52f72b91c6e9fbc7359d5a870f3
|
data/lib/ravioli/builder.rb
CHANGED
@@ -140,8 +140,8 @@ module Ravioli
|
|
140
140
|
end
|
141
141
|
|
142
142
|
# Load a file either with a given path or by name (e.g. `config/whatever.yml` or `:whatever`)
|
143
|
-
def load_file(path, options
|
144
|
-
config = parse_config_file(path, options)
|
143
|
+
def load_file(path, **options)
|
144
|
+
config = parse_config_file(path, **options)
|
145
145
|
configuration.append(config) if config.present?
|
146
146
|
rescue => error
|
147
147
|
warn "Could not load config file #{path}", error
|
@@ -221,10 +221,9 @@ module Ravioli
|
|
221
221
|
# rubocop:enable Style/MissingRespondToMissing
|
222
222
|
# rubocop:enable Style/MethodMissingSuper
|
223
223
|
|
224
|
-
def parse_config_file(path, options
|
224
|
+
def parse_config_file(path, **options)
|
225
225
|
# Stash a reference to the file we're parsing, so we can reload it later if it tries to use
|
226
226
|
# the configuration object
|
227
|
-
@current_path = path
|
228
227
|
path = path_to_config_file_path(path)
|
229
228
|
|
230
229
|
config = case path.extname.downcase
|
@@ -286,7 +285,7 @@ module Ravioli
|
|
286
285
|
def parse_yaml_config_file(path)
|
287
286
|
contents = File.read(path)
|
288
287
|
erb = ERB.new(contents).tap { |renderer| renderer.filename = path.to_s }
|
289
|
-
YAML.safe_load(erb.result, [Symbol], aliases: true)
|
288
|
+
YAML.safe_load(erb.result, permitted_classes: [Symbol], aliases: true)
|
290
289
|
end
|
291
290
|
|
292
291
|
def path_to_config_file_path(path, extnames: EXTNAMES, quiet: false)
|
data/lib/ravioli/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ravioli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Flip Sasser
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-05-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|