0.0
No commit activity in last 3 years
No release in over 3 years
Configuration storage library for Ruby with metaprogramming magic. Allows for hash-like and method-based key access.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 0.9.2
>= 2.6.0
 Project Readme

Configuratron build status still maintained

Configuratron is a library for storing configuraion. Objects of this class can access internal storage with a hash-like interface or method access:

require 'configuratron'
c = Configuratron.new
c[:setting] = :value
c[:setting] # => :value
c.other_setting = :other_value
c.other_setting # => :other_value

Method-based access is done by method_missing, but on first access the missing method is defined.

Configurable module

The Configuratron::Configurable module can either be included in a class, or extend it. When included, it will define a config method in instances of that class; when extended, it will define a config method for this class.

The config method returns a memoized instance of Configuratron.

License

This project is released under the MIT license. See LICENSE for more details.