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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f00c1e6723f460cadcdb4e628f8770101db83723
4
- data.tar.gz: 133f3d106b681fae18fa001f9bbf4386770d6ebd
3
+ metadata.gz: cd124b6f94ed39f9cb5f1b9f0251847f31d85e4c
4
+ data.tar.gz: e5b06604874f01f52c7de12b57c23f016c20c0a5
5
5
  SHA512:
6
- metadata.gz: 703e77e3fd176f17a40f1840941c19e74af32411ed2fb518193fa76b495a9977212fc6eab567a4d93a4a6dc1478bc5c2af12194a333fe702acac95474051104a
7
- data.tar.gz: b27c4493969d30fa486dd87c2237f5c6f0f3e98cb197e5def3a18928126c05b1857231b019875d7e307ebbc6b3329be9930a9a693d096d3eed2a9916c25dc7dc
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
1
+ 0.11.2
@@ -1,14 +1,14 @@
1
1
  # -*- encoding: utf-8 -*-
2
- # stub: complex_config 0.11.1 ruby lib
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.1"
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-27"
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 File.exist?(enc_pathname)
65
- key = key(pathname)
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(key).decrypt(text)
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"
@@ -1,6 +1,6 @@
1
1
  module ComplexConfig
2
2
  # ComplexConfig version
3
- VERSION = '0.11.1'
3
+ VERSION = '0.11.2'
4
4
  VERSION_ARRAY = VERSION.split('.').map(&:to_i) # :nodoc:
5
5
  VERSION_MAJOR = VERSION_ARRAY[0] # :nodoc:
6
6
  VERSION_MINOR = VERSION_ARRAY[1] # :nodoc:
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.1
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-27 00:00:00.000000000 Z
11
+ date: 2017-10-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gem_hadar