rb-konfig 0.1.5 → 0.1.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8e6f3dd52871d34e92d8a03de6ec2fd4ea05d2393a168e25e3d0a8b7b1e8c05e
4
- data.tar.gz: b69d8737c181ae24c43c9a4aee502f6af68fb2a1c290d5c8e090c36ad2a2d769
3
+ metadata.gz: d856585bd2b6c9b421964eb757e4dbc60b8a1e4a033e817c91353da2b9c0cc7a
4
+ data.tar.gz: c924badaff2dc5a2140c9559b4ea97c573590404593c050be3ca32ed7d66a15c
5
5
  SHA512:
6
- metadata.gz: 63e9948892cd048da2602d3d7f0f2434164a9681b91c3f94e321f09ea05d84a3ad1ef03a69214c5fc869c9bb72d9f055a2ed85336f34ba29b03352591745a440
7
- data.tar.gz: 80e7fd214685cd632f9ccb44eed8dd254c9ec07a1d607736d309cbb631dae00887cf4789497b67bde3ef9efa5293619ce6dec8472c1b3428a882ccc046d1a7e3
6
+ metadata.gz: d180c690f4d3747ce7da2aa8e459c0d8df4a3241ec3853c439bc70c0a69b8a6ddb15f65f137fc4724e1b993df25d36eb2ddc4dd653f957f8a465a2bbf0dc82d0
7
+ data.tar.gz: e3702b812b5eaa692db87f3eb737c4b77981410c448bc304828fc085249c8134db2aa0b1df6f90f19e73e00565efea3a7eec231fe2c2299cf5cb36f44ecbd869
data/.gitignore CHANGED
@@ -50,3 +50,4 @@ build-iPhoneSimulator/
50
50
  .rvmrc
51
51
  /.byebug_history
52
52
  /.idea
53
+ /.DS_Store
data/.ruby-version CHANGED
@@ -1,2 +1,2 @@
1
- ruby-2.5.5
1
+ 3.0.0
2
2
 
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- rb-konfig (0.1.4)
4
+ rb-konfig (0.1.5)
5
5
  activesupport (>= 4)
6
6
  dry-schema (~> 1.3)
7
7
  thor (~> 0.20)
data/konfig.gemspec CHANGED
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
26
26
 
27
27
  spec.add_dependency "activesupport", ">= 4"
28
28
  spec.add_dependency "dry-schema", "~> 1.3"
29
- spec.add_dependency "thor", "~> 0.20"
29
+ spec.add_dependency "thor", "~> 1.0"
30
30
 
31
31
  spec.add_development_dependency "bundler", "~> 2.0"
32
32
  spec.add_development_dependency "rake", "~> 10.0"
data/lib/konfig.rb CHANGED
@@ -45,12 +45,13 @@ module Konfig
45
45
  end
46
46
 
47
47
  def logger
48
- @logger if @logger
48
+ return @logger if @logger
49
49
  if defined?(Rails) && Rails.logger
50
- Rails.logger
50
+ @logger = Rails.logger
51
51
  else
52
- Logger.new(STDOUT)
52
+ @logger = Logger.new(STDOUT)
53
53
  end
54
+ @logger
54
55
  end
55
56
 
56
57
  def schema=(value)
data/lib/konfig/option.rb CHANGED
@@ -94,8 +94,7 @@ module Konfig
94
94
  s = self.class.new
95
95
 
96
96
  h.each do |k, v|
97
- k = k.to_s if !k.respond_to?(:to_sym) && k.respond_to?(:to_s)
98
- s.new_ostruct_member(k)
97
+ k = k.to_s if !k.respond_to?(:to_sym) && k.respond_to?(:to_s)
99
98
 
100
99
  if v.is_a?(Hash)
101
100
  v = v["type"] == "hash" ? v["contents"] : __convert(v)
@@ -103,7 +102,7 @@ module Konfig
103
102
  v = v.collect { |e| e.instance_of?(Hash) ? __convert(e) : e }
104
103
  end
105
104
 
106
- s.send("#{k}=".to_sym, v)
105
+ s[k] = v
107
106
  end
108
107
  s
109
108
  end
@@ -1,3 +1,3 @@
1
1
  module Konfig
2
- VERSION ||= "0.1.5"
2
+ VERSION ||= "0.1.6"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rb-konfig
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Khash Sajadi
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-25 00:00:00.000000000 Z
11
+ date: 2021-03-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0.20'
47
+ version: '1.0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '0.20'
54
+ version: '1.0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: bundler
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -164,7 +164,7 @@ dependencies:
164
164
  - - "~>"
165
165
  - !ruby/object:Gem::Version
166
166
  version: '11.0'
167
- description:
167
+ description:
168
168
  email:
169
169
  - hello@cloud66.com
170
170
  executables:
@@ -204,7 +204,7 @@ licenses: []
204
204
  metadata:
205
205
  homepage_uri: https://github.com/cloud66-oss/konfig/
206
206
  source_code_uri: https://github.com/cloud66-oss/konfig/
207
- post_install_message:
207
+ post_install_message:
208
208
  rdoc_options: []
209
209
  require_paths:
210
210
  - lib
@@ -219,9 +219,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
219
219
  - !ruby/object:Gem::Version
220
220
  version: '0'
221
221
  requirements: []
222
- rubyforge_project:
223
- rubygems_version: 2.7.6.2
224
- signing_key:
222
+ rubygems_version: 3.2.3
223
+ signing_key:
225
224
  specification_version: 4
226
225
  summary: Konfig is a Kubernetes friendly Rails configuration gem
227
226
  test_files: []