diff --git a/cmd/csaf_aggregator/config.go b/cmd/csaf_aggregator/config.go index eefcc3b..8962a05 100644 --- a/cmd/csaf_aggregator/config.go +++ b/cmd/csaf_aggregator/config.go @@ -132,8 +132,9 @@ type config struct { // configPaths are the potential file locations of the config file. var configPaths = []string{ - // TODO: Make symmetric to checker and downloader. - "aggregator.toml", + "~/.config/csaf/aggregator.toml", + "~/.csaf_aggregator.toml", + "csaf_aggregator.toml", } // parseArgsConfig parse the command arguments and loads configuration diff --git a/docs/csaf_aggregator.md b/docs/csaf_aggregator.md index df250b4..08cbae0 100644 --- a/docs/csaf_aggregator.md +++ b/docs/csaf_aggregator.md @@ -15,6 +15,15 @@ Help Options: -h, --help Show this help message ``` +If no config file is explictly given the follwing places are searched for a config file: +``` +~/.config/csaf/aggregator.toml +~/.csaf_aggregator.toml +csaf_aggregator.toml +``` + +with `~` expanding to `$HOME` on unixoid systems and `%HOMEPATH` on Windows systems. + Usage example for a single run, to test if the config is good: ```bash ./csaf_aggregator -c docs/examples/aggregator.toml