Closed yaozhihang closed 8 months ago
Thanks, @yaozhihang. I like the generic and thin config module. Gives us a lot of flexibility. So let's merge. If we think we need more predefined structure in the future, it's easy to add.
One minor question. Currently the config file would look like this:
{
"configs:" {
}
}
Should we use a @JSONField
annotation to rename "configs" to "config" or "configuration"? I somehow prefer the singular form here because this is the config file. Or we could use "options"? And in future we could even add more metadata like version or type, for example:
{
"type": "citydb-tool",
"version": "1.0",
"config:" {
}
}
Thanks, @yaozhihang. I like the generic and thin config module. Gives us a lot of flexibility. So let's merge. If we think we need more predefined structure in the future, it's easy to add.
One minor question. Currently the config file would look like this:
{ "configs:" { } }
Should we use a
@JSONField
annotation to rename "configs" to "config" or "configuration"? I somehow prefer the singular form here because this is the config file. Or we could use "options"? And in future we could even add more metadata like version or type, for example:{ "type": "citydb-tool", "version": "1.0", "config:" { } }
Yes, agree. Done with c1259ff3
This PR adds a new
config
module. The configurations like read and write options, import and export options, as well as plugin configs can be encoded in a JSON file and managed by this module.Example config json: test-config.json