diff --git a/khal/khalendar/event.py b/khal/khalendar/event.py index 3af1531cd..45782fb6f 100644 --- a/khal/khalendar/event.py +++ b/khal/khalendar/event.py @@ -645,6 +645,8 @@ def attributes( attributes["end-date-long"] = self.end_local.strftime(self._locale['longdateformat']) attributes["end-time"] = self.end_local.strftime(self._locale['timeformat']) + attributes["current-date"] = relative_to_start.strftime(self._locale['dateformat']) + attributes["duration"] = timedelta2str(self.duration) # should only have time attributes at this point (start/end) diff --git a/khal/utils.py b/khal/utils.py index 4e7d4e70f..b113f6a63 100644 --- a/khal/utils.py +++ b/khal/utils.py @@ -221,7 +221,8 @@ def fmt(rows): 'start-style', 'end-style', 'to-style', 'start-end-time-style', 'end-necessary', 'end-necessary-long', 'repeat-symbol', 'repeat-pattern', 'title', 'organizer', 'description', 'location', 'all-day', 'categories', - 'uid', 'url', 'calendar', 'calendar-color', 'status', 'cancelled'] + 'uid', 'url', 'calendar', 'calendar-color', 'status', 'cancelled', + 'current-date'] def json_formatter(fields):