dry-configurable 1.0.0 → 1.0.1
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
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a9dc2db3ddad9ce63a4129b8792a0d0fc26695169015c33721d49a153a3972bc
|
4
|
+
data.tar.gz: 67b7b36444ac64bd06bd0800e5ac74aaced969aa74b31bd686f8e7ecbc4b6b85
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 32317f78da754f348e1b4cda2817d81d48ca0cc32fb2b8cedff62d499589063d8c7b3f54917114f37412007593ca44c6d33d99c87ab44d5fa3dcbd13684c3bb1
|
7
|
+
data.tar.gz: 373c4b8e6d9fcd015acae6b5aebaa82a307a57a1a541480a7c2887f6bba2c24c80992c9f1352e9a97caea3f21e857ebb23a94a0c43f8598332425f942e49794f
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,23 @@
|
|
1
1
|
<!--- DO NOT EDIT THIS FILE - IT'S AUTOMATICALLY GENERATED VIA DEVTOOLS --->
|
2
2
|
|
3
|
+
## 1.0.1 2022-11-16
|
4
|
+
|
5
|
+
|
6
|
+
### Changed
|
7
|
+
|
8
|
+
- Renamed `@config` and `@_settings` internal instance variables to `@__config__` and `@__settings__` in order to avoid clashes with user-defined instance variables (#159 by @timriley)
|
9
|
+
|
10
|
+
[Compare v1.0.0...v1.0.1](https://github.com/dry-rb/dry-configurable/compare/v1.0.0...v1.0.1)
|
11
|
+
|
12
|
+
## 1.0.0 2022-11-04
|
13
|
+
|
14
|
+
|
15
|
+
### Changed
|
16
|
+
|
17
|
+
- Dependency on `dry-core` was updated to ~> 1.0 (@solnic)
|
18
|
+
|
19
|
+
[Compare v0.16.1...v1.0.0](https://github.com/dry-rb/dry-configurable/compare/v0.16.1...v1.0.0)
|
20
|
+
|
3
21
|
## 0.16.1 2022-10-13
|
4
22
|
|
5
23
|
|
@@ -14,13 +14,13 @@ module Dry
|
|
14
14
|
subclass.instance_variable_set(:@__config_extension__, __config_extension__)
|
15
15
|
|
16
16
|
new_settings = settings.dup
|
17
|
-
subclass.instance_variable_set(:@
|
17
|
+
subclass.instance_variable_set(:@__settings__, new_settings)
|
18
18
|
|
19
19
|
# Only classes **extending** Dry::Configurable have class-level config. When
|
20
20
|
# Dry::Configurable is **included**, the class-level config method is undefined because it
|
21
21
|
# resides at the instance-level instead (see `Configurable.included`).
|
22
22
|
if respond_to?(:config)
|
23
|
-
subclass.instance_variable_set(:@
|
23
|
+
subclass.instance_variable_set(:@__config__, config.dup_for_settings(new_settings))
|
24
24
|
end
|
25
25
|
end
|
26
26
|
|
@@ -56,7 +56,7 @@ module Dry
|
|
56
56
|
#
|
57
57
|
# @api public
|
58
58
|
def settings
|
59
|
-
@
|
59
|
+
@__settings__ ||= Settings.new
|
60
60
|
end
|
61
61
|
|
62
62
|
# Return configuration
|
@@ -65,7 +65,7 @@ module Dry
|
|
65
65
|
#
|
66
66
|
# @api public
|
67
67
|
def config
|
68
|
-
@
|
68
|
+
@__config__ ||= __config_build__
|
69
69
|
end
|
70
70
|
|
71
71
|
# @api private
|
@@ -12,7 +12,7 @@ module Dry
|
|
12
12
|
module Initializer
|
13
13
|
# @api private
|
14
14
|
def initialize(*)
|
15
|
-
@
|
15
|
+
@__config__ = self.class.__config_build__(self.class.settings)
|
16
16
|
|
17
17
|
super
|
18
18
|
end
|
@@ -30,7 +30,9 @@ module Dry
|
|
30
30
|
# @return [Config]
|
31
31
|
#
|
32
32
|
# @api public
|
33
|
-
|
33
|
+
def config
|
34
|
+
@__config__
|
35
|
+
end
|
34
36
|
|
35
37
|
# Finalize the config and freeze the object
|
36
38
|
#
|
@@ -45,7 +47,7 @@ module Dry
|
|
45
47
|
# @api public
|
46
48
|
def initialize_copy(source)
|
47
49
|
super
|
48
|
-
@
|
50
|
+
@__config__ = source.config.dup
|
49
51
|
end
|
50
52
|
end
|
51
53
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dry-configurable
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andy Holland
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-11-
|
11
|
+
date: 2022-11-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dry-core
|