Documentation ¶
Overview ¶
config contains the loggic around config files for Armaria. The config file is a simple toml file.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrConfigMissing = errors.New("config missing")
ErrConfigMissing is returned when the config file is missing.
Functions ¶
func UpdateConfig ¶
func UpdateConfig(folderPath string, configPath string, update UpdateConfigCallback) error
UpdateConfig updates the current config. It will be created if it hasn't already been created.
Types ¶
type Config ¶
type Config struct {
DB string `koanf:"db"`
}
Config is the configuration for Armaria.
type UpdateConfigCallback ¶
type UpdateConfigCallback func(config *Config)
UpdateConfigCallback is a callback to update the current config
Click to show internal directories.
Click to hide internal directories.