complex_config 0.11.1 → 0.11.2
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/README.md +6 -1
- data/VERSION +1 -1
- data/complex_config.gemspec +3 -3
- data/lib/complex_config/provider.rb +5 -3
- data/lib/complex_config/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: cd124b6f94ed39f9cb5f1b9f0251847f31d85e4c
|
|
4
|
+
data.tar.gz: e5b06604874f01f52c7de12b57c23f016c20c0a5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 970b5049209c089c17084a167978b8223a3af830fb635dec38b36736e060115eb2408a1977be9163f0abab14e719dc2bc40815cc7b715a5eee54b2d5c5de7e23
|
|
7
|
+
data.tar.gz: fd42383b7a7e505fdc6b0ae25258248c2d9a417f42192ea28c9c38e5ac3a3c15c0342fa228d41dc614577aa94ab7d2c124f38fac6c28db150b94158873400079
|
data/README.md
CHANGED
|
@@ -143,7 +143,12 @@ Here is the `ComplexConfig::Plugins::MONEY` plugin for example:
|
|
|
143
143
|
end
|
|
144
144
|
|
|
145
145
|
## Changes
|
|
146
|
-
|
|
146
|
+
* 2017-10-30 Release 0.11.2
|
|
147
|
+
* Small bugfix
|
|
148
|
+
* 2017-10-27 Release 0.11.1
|
|
149
|
+
* Small bugfix
|
|
150
|
+
* 2017-10-27 Release 0.11.0
|
|
151
|
+
* Support encrypted config files a la rails
|
|
147
152
|
* 2017-02-02 Release 0.10.0
|
|
148
153
|
* `cc.foo?`/`complex_config.foo?` returns config or nil (when not existant)
|
|
149
154
|
* 2017-01-23 Release 0.9.2
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.11.
|
|
1
|
+
0.11.2
|
data/complex_config.gemspec
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
|
2
|
-
# stub: complex_config 0.11.
|
|
2
|
+
# stub: complex_config 0.11.2 ruby lib
|
|
3
3
|
|
|
4
4
|
Gem::Specification.new do |s|
|
|
5
5
|
s.name = "complex_config".freeze
|
|
6
|
-
s.version = "0.11.
|
|
6
|
+
s.version = "0.11.2"
|
|
7
7
|
|
|
8
8
|
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
|
9
9
|
s.require_paths = ["lib".freeze]
|
|
10
10
|
s.authors = ["Florian Frank".freeze]
|
|
11
|
-
s.date = "2017-10-
|
|
11
|
+
s.date = "2017-10-30"
|
|
12
12
|
s.description = "This library allows you to access configuration files via a simple interface".freeze
|
|
13
13
|
s.email = "flori@ping.de".freeze
|
|
14
14
|
s.extra_rdoc_files = ["README.md".freeze, "lib/complex_config.rb".freeze, "lib/complex_config/config.rb".freeze, "lib/complex_config/encryption.rb".freeze, "lib/complex_config/errors.rb".freeze, "lib/complex_config/plugins.rb".freeze, "lib/complex_config/plugins/enable.rb".freeze, "lib/complex_config/plugins/money.rb".freeze, "lib/complex_config/plugins/uri.rb".freeze, "lib/complex_config/provider.rb".freeze, "lib/complex_config/provider/shortcuts.rb".freeze, "lib/complex_config/proxy.rb".freeze, "lib/complex_config/railtie.rb".freeze, "lib/complex_config/rude.rb".freeze, "lib/complex_config/settings.rb".freeze, "lib/complex_config/shortcuts.rb".freeze, "lib/complex_config/version.rb".freeze]
|
|
@@ -61,10 +61,12 @@ class ComplexConfig::Provider
|
|
|
61
61
|
if File.exist?(pathname)
|
|
62
62
|
datas << IO.binread(pathname)
|
|
63
63
|
end
|
|
64
|
-
if enc_pathname = pathname.to_s + '.enc' and
|
|
65
|
-
|
|
64
|
+
if enc_pathname = pathname.to_s + '.enc' and
|
|
65
|
+
File.exist?(enc_pathname) and
|
|
66
|
+
my_key = key(pathname)
|
|
67
|
+
then
|
|
66
68
|
text = IO.binread(enc_pathname)
|
|
67
|
-
datas << ComplexConfig::Encryption.new(
|
|
69
|
+
datas << ComplexConfig::Encryption.new(my_key).decrypt(text)
|
|
68
70
|
end
|
|
69
71
|
datas.empty? and raise ComplexConfig::ConfigurationFileMissing,
|
|
70
72
|
"configuration file #{pathname.inspect} is missing"
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: complex_config
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.11.
|
|
4
|
+
version: 0.11.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Florian Frank
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-10-
|
|
11
|
+
date: 2017-10-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: gem_hadar
|