config: remove default values for this-*-time-format

Having a default value is confusing because to disable the dynamic time
format, the users need to explicitly configure these settings to the
empty string.

Do not set default values for these settings when they are unset in the
configuration. Comment the default config file values to serve as
examples.

Fixes: aae29324fd ("config: fix default time format values")
Reported-by: Nicolai Dagestad <nicolai@dagestad.fr>
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
This commit is contained in:
Robin Jarry 2022-09-25 10:51:22 +02:00
parent 9fdc7acf5b
commit 24e30f7f1f
3 changed files with 12 additions and 12 deletions
config

View file

@ -736,9 +736,9 @@ func LoadConfigFromFile(root *string, accts []string) (*AercConfig, error) {
Ui: UIConfig{
IndexFormat: "%-20.20D %-17.17n %Z %s",
TimestampFormat: "2006-01-02 03:04 PM",
ThisDayTimeFormat: "03:04 PM",
ThisWeekTimeFormat: "Monday 03:04 PM",
ThisYearTimeFormat: "January 02",
ThisDayTimeFormat: "",
ThisWeekTimeFormat: "",
ThisYearTimeFormat: "",
ShowHeaders: []string{
"From", "To", "Cc", "Bcc", "Subject", "Date",
},