dry-configurable 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +12 -2
- data/lib/dry/configurable/dsl.rb +1 -1
- data/lib/dry/configurable/errors.rb +8 -1
- data/lib/dry/configurable/extension.rb +2 -4
- data/lib/dry/configurable/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 94af5d96e13582f8cdd76f5dad132ac8228b5bbb3d288b1c78ea7b976b925935
|
4
|
+
data.tar.gz: 3d33f7cf5b5cdbce76d2e9531bd8ba52919fad3c9c852c3b401ee41a14a62bae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a78071b550e270e74a8c4eafacf9a42aec8d5fd4c7c85f3e3919ade358d92abc232b1617ed1ba6cc04edfdd7c47e427b7c7b9f44c5cba3290b67c125e38cb59c
|
7
|
+
data.tar.gz: 3c6f5ae84fc9dc9c728ed955834a3d4b6d9e6e833b189002206412d4d803345422335d410dbcda2b6de21e491231eedae24e6e893785c4fc8108938f58178f9f
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,16 @@
|
|
1
1
|
<!--- DO NOT EDIT THIS FILE - IT'S AUTOMATICALLY GENERATED VIA DEVTOOLS --->
|
2
2
|
|
3
|
-
## 1.0
|
3
|
+
## 1.2.0 2024-07-03
|
4
|
+
|
5
|
+
|
6
|
+
### Changed
|
7
|
+
|
8
|
+
- Allow `Dry::Configurable` mixin to be included multiple times in a class hierarchy (#164 by @timriley)
|
9
|
+
- Deprecate `Dry::Configurable::AlreadyIncludedError` (#164 by @timriley)
|
10
|
+
|
11
|
+
[Compare v1.1.0...v1.2.0](https://github.com/dry-rb/dry-configurable/compare/v1.1.0...v1.2.0)
|
12
|
+
|
13
|
+
## 1.1.0 2022-07-16
|
4
14
|
|
5
15
|
|
6
16
|
### Fixed
|
@@ -8,7 +18,7 @@
|
|
8
18
|
- Allow nested settings to default to `Undefined` (fixes #158 via #161) (@emptyflask)
|
9
19
|
|
10
20
|
|
11
|
-
[Compare v1.0.1...v1.0
|
21
|
+
[Compare v1.0.1...v1.1.0](https://github.com/dry-rb/dry-configurable/compare/v1.0.1...v1.1.0)
|
12
22
|
|
13
23
|
## 1.0.1 2022-11-16
|
14
24
|
|
data/lib/dry/configurable/dsl.rb
CHANGED
@@ -26,7 +26,7 @@ module Dry
|
|
26
26
|
# @see ClassMethods.setting
|
27
27
|
# @api private
|
28
28
|
# @return Setting
|
29
|
-
def setting(name, **options, &block)
|
29
|
+
def setting(name, **options, &block)
|
30
30
|
unless VALID_NAME.match?(name.to_s)
|
31
31
|
raise ArgumentError, "#{name} is not a valid setting name"
|
32
32
|
end
|
@@ -5,9 +5,16 @@ module Dry
|
|
5
5
|
#
|
6
6
|
# @api public
|
7
7
|
module Configurable
|
8
|
+
extend Dry::Core::Deprecations["dry-configurable"]
|
9
|
+
|
8
10
|
Error = Class.new(::StandardError)
|
9
11
|
|
10
|
-
AlreadyIncludedError = Class.new(Error)
|
11
12
|
FrozenConfigError = Class.new(Error)
|
13
|
+
|
14
|
+
AlreadyIncludedError = Class.new(Error)
|
15
|
+
deprecate_constant(
|
16
|
+
:AlreadyIncludedError,
|
17
|
+
message: "`include Dry::Configurable` more than once (if needed)"
|
18
|
+
)
|
12
19
|
end
|
13
20
|
end
|
@@ -26,8 +26,6 @@ module Dry
|
|
26
26
|
|
27
27
|
# @api private
|
28
28
|
def included(klass)
|
29
|
-
raise AlreadyIncludedError if klass.include?(InstanceMethods)
|
30
|
-
|
31
29
|
super
|
32
30
|
|
33
31
|
klass.class_eval do
|
@@ -36,8 +34,8 @@ module Dry
|
|
36
34
|
prepend(Initializer)
|
37
35
|
|
38
36
|
class << self
|
39
|
-
undef :config
|
40
|
-
undef :configure
|
37
|
+
undef :config if method_defined?(:config)
|
38
|
+
undef :configure if method_defined?(:configure)
|
41
39
|
end
|
42
40
|
end
|
43
41
|
|
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.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andy Holland
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-07-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dry-core
|
@@ -135,7 +135,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
135
135
|
- !ruby/object:Gem::Version
|
136
136
|
version: '0'
|
137
137
|
requirements: []
|
138
|
-
rubygems_version: 3.3.
|
138
|
+
rubygems_version: 3.3.27
|
139
139
|
signing_key:
|
140
140
|
specification_version: 4
|
141
141
|
summary: A mixin to add configuration functionality to your classes
|