Skip to content

Commit

Permalink
Docs: date/time formats may need to be quoted in config files
Browse files Browse the repository at this point in the history
Closes #1007
  • Loading branch information
d7415 committed Mar 7, 2021
1 parent 03e037c commit fc14516
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions khal.conf.sample
Expand Up @@ -15,6 +15,8 @@ path = ~/.khal/khal.db
local_timezone = Europe/Berlin
default_timezone = America/New_York

# If you use certain characters (e.g. commas) in these formats you may need to
# enclose them in "" to ensure that they are loaded as strings.
timeformat = %H:%M
dateformat = %d.%m.
longdateformat = %d.%m.%Y
Expand Down
3 changes: 3 additions & 0 deletions khal/settings/khal.spec
Expand Up @@ -98,6 +98,9 @@ local_timezone = timezone(default=None)
# The formatting string is interpreted as defined by Python's `strftime
# <https://docs.python.org/3/library/time.html#time.strftime>`_, which is
# similar to the format specified in ``man strftime``.

# In the configuration file it may be necessary to enclose the format in
# quotation marks to force it to be loaded as a string.
timeformat = string(default='%X')

# khal will display and understand all dates in this format, see :ref:`timeformat <locale-timeformat>` for the format
Expand Down

0 comments on commit fc14516

Please sign in to comment.