github.com/cristalhq/aconfig (go): Package aconfig provides simple but still powerful config loader.  It can read configuration from different sources, like defaults, files, environment variables, console flag parameters.  Defaults are defined in structure tags (`default` tag). For files JSON, YAML, TOML and .Env are supported.  Environment variables and flag parameters can have an optional prefix to separate them from other entries.  Also, aconfig is dependency-free, file decoders are used as separate modules (submodules to be exact) and are added to your go.mod only when used.  Loader configuration (`Config` type) has different ways to configure loader, to skip some sources, define prefixes, fail on unknown params.  Just load defaults from struct definition.   Load defaults from struct definition and overwrite with a file. And then overwrite with environment variables.   Load defaults from struct defunition and overwrite with a file.   Load defaults from struct definition and overwrite with a file. And then overwrite with environment variables. Finally read command line flags.
Keywords: command-line|config|configuration|configuration-files|dependency-free|environment|environment-variables|go|golang|json|toml|yaml