I just released Enviable v1.5, which is mostly a bugfix release, but added a couple of minor features.
I’m not sure when (or if) Enviable 2 will be released, but when it does, the default behaviour of boolean conversion will be to be case-insensitive. To make that transition easier, I added a compile-time option (:enviable, :boolean_downcase) that can be set to :default to match the eventual default and keep your fetch_env_as_boolean! calls simpler).
Although get_env_as_json and related functions documented that the default engine could be configured with :enviable, :json_engine, the code supporting that was incorrect in two ways: it was being evaluated at runtime, not at compile time, and it was using :enviable, :json instead of :enviable, :json_engine. This has been fixed and specifying the JSON engine now allows for an MFA tuple either as a parameter or as a compile configuration.
Changelog
-
Fixed a bug with
listconversion forget_env_as_listandget_env_aswhere support for a:defaultvalue was not included. -
Fixed a bug with
:downcaseconversions and nil values. -
Added a compile-time configuration option to change the default boolean
:downcaseoption. The default value is currentlyfalse(do not downcase). The next major version of Enviable will change this to:default, as it should not matter whether the matched value istrue,TRUE, orTruefor boolean tests. -
Added
:upcaseoption toatomandsafe_atomconversions. -
Fixed
:json_engineconfiguration so that it is properly compile-time and referenced. The JSON parsing code was looking this up at runtime under the wrong key. -
Added support for
{m, f, a}specification for:json_engineconfiguration or the:engineparameter for JSON conversion.






















