3.3 KiB
3.3 KiB
0.9.0 - 2019-11-06
Fixed
- Support for reserved names in settings. Some Kernel methods (
public_send
andclass
specifically) are not available if you use access settings via method call. Same for methods of theConfig
class. You can still access them with[]
and[]=
. Ruby keywords are fully supported. Invalid names containing special symbols (including!
and?
) are rejected. Note that these changes don't affect thereader
option, if you define a setting named:class
and passreader: true
... well ... (flash-gordon) - Settings can be redefined in subclasses without a warning about overriding exsting methods (flash-gordon)
- Fix warnings about using keyword arguments in 2.7 (koic)
0.8.3 - 2019-05-29
Fixed
Configurable#dup
andConfigurable#clone
make a copy of instance-level config so that it doesn't get mutated/shared across instances (flash-gordon)
0.8.2 - 2019-02-25
Fixed
- Test interface support for modules (Neznauy)
0.8.1 - 2019-02-06
Fixed
.configure
doesn't require a block, this makes the behavior consistent with the previous versions (flash-gordon)
0.8.0 - 2019-02-05
Fixed
- A number of bugs related to inheriting settings from parent class were fixed. Ideally, new behavior will be 💯 predictable but if you observe any anomaly, please report (flash-gordon)
Added
-
Support for instance-level configuration landed. For usage,
include
the module instead of extending (flash-gordon)class App include Dry::Configurable setting :database end production = App.new production.config.database = ENV['DATABASE_URL'] production.finalize! development = App.new development.config.database = 'jdbc:sqlite:memory' development.finalize!
-
Config values can be set from a hash with
.update
. Nested settings are supported (flash-gordon)class App extend Dry::Configurable setting :db do setting :host setting :port end config.update(YAML.load(File.read("config.yml"))) end
Changed
- [BREAKING] Minimal supported Ruby version is set to 2.3 (flash-gordon)
0.7.0 - 2017-04-25
Added
- Introduce
Configurable.finalize!
which freezes config and its dependencies (qcam)
Fixed
- Allow for boolean false as default setting value (yuszuv)
- Convert nested configs to nested hashes with
Config#to_h
(saverio-kantox) - Disallow modification on frozen config (qcam)