ultra_config 0.5.0 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ultra_config/namespace.rb +8 -4
- data/ultra_config.gemspec +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: 45e3cd0b3e5c162a02035c400998f8032e5f3870
|
4
|
+
data.tar.gz: ddc1e423404d068d18a42017eb35283048107ff1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 224b1be537616646332bc2647b088584fb88e55639a4c801e51c6bb6909ca1dd6b6b0c576868d6946c7c6e2b26377404fb680a161d0ad6cd5c567fa3294b92da
|
7
|
+
data.tar.gz: e7a5552fb37d6f859470f166f36029dba942fd54be780ecde2cfe4b86f97c2a2d5bf44390d94b7a7957a600310666a121a31c1ef70511b2f2537138b7a8d8ed3
|
@@ -7,6 +7,10 @@ module UltraConfig
|
|
7
7
|
reset
|
8
8
|
end
|
9
9
|
|
10
|
+
def setting(name, value)
|
11
|
+
Settings.set(name, value)
|
12
|
+
end
|
13
|
+
|
10
14
|
def namespace(name, &block)
|
11
15
|
@objects[name] = Namespace.new(&block)
|
12
16
|
end
|
@@ -15,6 +19,10 @@ module UltraConfig
|
|
15
19
|
@objects[name] = Config.new(default, &block)
|
16
20
|
end
|
17
21
|
|
22
|
+
def helper(name, &block)
|
23
|
+
define_singleton_method(name, &block)
|
24
|
+
end
|
25
|
+
|
18
26
|
def method_missing(m, *args)
|
19
27
|
if m.to_s.end_with?('=')
|
20
28
|
@objects[m.to_s[0...-1].to_sym].value=(args[0])
|
@@ -23,10 +31,6 @@ module UltraConfig
|
|
23
31
|
end
|
24
32
|
end
|
25
33
|
|
26
|
-
def setting(name, value)
|
27
|
-
Settings.set(name, value)
|
28
|
-
end
|
29
|
-
|
30
34
|
def reset
|
31
35
|
@objects = {}
|
32
36
|
self.instance_eval(&@configuration)
|
data/ultra_config.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ultra_config
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gregory Kuruc
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-06-
|
11
|
+
date: 2018-06-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|