Apparently Config already allows you to config it programmatically. However, refinery-core (used by refinery) uses serde by default to support serialization and deserialization of this type.
This is unnecessary if you don't use refinery-cli and configure it programmatically (using the set_xxx methods).
On top of that, refinery makes the assumption that Toml will be used to deserialize/serialize this type, as toml dependency is used as well in refinery-core by default. Again it's not always the case, this is more related with refinery-cli.
I suggest declaring both toml and serde dependencies as optional, under a feature flag. They can appear under the default-features, if they are used so often. It will also help not breaking anyone's code.
Apparently Config already allows you to config it programmatically. However,
refinery-core
(used byrefinery
) uses serde by default to support serialization and deserialization of this type.This is unnecessary if you don't use
refinery-cli
and configure it programmatically (using theset_xxx
methods).On top of that,
refinery
makes the assumption that Toml will be used to deserialize/serialize this type, as toml dependency is used as well inrefinery-core
by default. Again it's not always the case, this is more related withrefinery-cli
.I suggest declaring both toml and serde dependencies as optional, under a feature flag. They can appear under the
default-features
, if they are used so often. It will also help not breaking anyone's code.