Releases: carueda/tscfg
Scala: now targeting 2.13 by default, with new flag for 2.12
Many thanks to @johanneshiry for this contribution!
This new release only impacts the Scala generation: tscfg now targets 2.13 by default, with a new --scala:2.12
flag as a mechanism for any need for compatibility with 2.12 as in previous releases. In general, the distinction is only relevant for configuration specs involving lists.
See #59 for more details.
Bug fix release
Should fix this particular misbehavior: #54 (comment) (thanks @kirkbro for reporting).
Shared config objects #54
Bug fix release
Given config now fully validated at wrapper construction
Resolves #49 (which also supersedes #36).
For both java and scala, in case of any missing or incompatible types in the given configuration, wrapper construction will now throw a com.typesafe.config.ConfigException
with a summary of all the corresponding com.typesafe.config.ConfigException
's collected as the constructor traverses the configuration.
Example of such a summary:
Invalid configuration:
'service.poolSize': com.typesafe.config.ConfigException$Missing(No configuration setting found for key 'poolSize')
'service.url': com.typesafe.config.ConfigException$Missing(No configuration setting found for key 'url')
'service.debug': com.typesafe.config.ConfigException$WrongType(String: 5: debug has type NUMBER rather than BOOLEAN)
'service.doLog': com.typesafe.config.ConfigException$WrongType(String: 6: doLog has type STRING rather than BOOLEAN)
'service.factor': com.typesafe.config.ConfigException$WrongType(String: 7: factor has type BOOLEAN rather than NUMBER)
(Note: command-line option --scala:fp
is now obsolete, still accepted but ignored.)
New `--all-required` flag
The new --all-required
flag strictly forces all entries (even objects) to be required (even the @optional
annotation is ignored). Thanks @abonander for the suggestion (#47).
new `--durations` flag
New --durations
flag to generate java.time.Duration
as base type for duration instead of long
. Thanks @qux42!
new `--java:optionals` option
New --java:optionals
option to generate Optional<T>
for optional fields in java. Thanks @qux42 !
Bug fix release
- String-to-bytes conversion results in compilation error - #40 (thanks @opensorceror)
- Generate default config objects if non-existent - #33 (thanks @JustinPihony). Sorry! it seems the previously published v.0.9.4 didn't actually contain this. Anyway, it is now included in v.0.9.6.
Bug fix release
- Generate default config objects if non-existent #33 - Thanks @JustinPihony !