summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorA Frederick Christensen <fauxmight@nosocomia.com>2017-09-24 01:35:42 -0400
committerA Frederick Christensen <fauxmight@nosocomia.com>2017-09-24 01:35:42 -0400
commit9576705786d2d27c10669549c7081a4782ce090d (patch)
tree29dd3509e457bdc6903cbf5397bfa68d7e41ef48
parent8df06a8c825a1244788b301b7e20ed79707c8740 (diff)
downloadcalendar-cli-9576705786d2d27c10669549c7081a4782ce090d.zip
Fix --whole-day capability
-rwxr-xr-xcalendar-cli.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/calendar-cli.py b/calendar-cli.py
index 269140e..2d2ed3e 100755
--- a/calendar-cli.py
+++ b/calendar-cli.py
@@ -292,8 +292,8 @@ def calendar_add(caldav_conn, args):
duration = int(event_spec[1][:-1])
dtstart = dateutil.parser.parse(event_spec[0])
dtend = dtstart + timedelta(days=duration)
- event.add('dtstart', _date(dtstart.date))
- event.add('dtend', _date(dtend.date))
+ event.add('dtstart', _date(dtstart.date()))
+ event.add('dtend', _date(dtend.date()))
else:
event.add('dtstart', dtstart)
## TODO: handle duration and end-time as options. default 3600s by now.