summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Brox <tobias@redpill-linpro.com>2020-06-07 11:35:14 +0200
committerTobias Brox <tobias@redpill-linpro.com>2020-06-07 11:35:14 +0200
commit1727c49082bbdf898b0dc5ea309b847e249bb94c (patch)
tree8d93207f88d4aa7cb092fd86a2248ca07952e866
parentaa13a2c65888a79fc40848fa19efe194feb065fb (diff)
downloadcalendar-cli-1727c49082bbdf898b0dc5ea309b847e249bb94c.zip
bugfixing
-rwxr-xr-xcalendar-cli.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/calendar-cli.py b/calendar-cli.py
index 642e453..7257beb 100755
--- a/calendar-cli.py
+++ b/calendar-cli.py
@@ -502,7 +502,7 @@ def calendar_agenda(caldav_conn, args):
dtstart = datetime(dtstart.year, dtstart.month, dtstart.day)
else:
if not dtstart.tzinfo:
- dtstart.localize(tzinfo)
+ tzinfo.localize(dtstart)
## convert into timezone given in args:
dtstart = dtstart.astimezone(_tz(args.timezone))
@@ -874,7 +874,7 @@ def main():
todo_add_parser.set_defaults(func=todo_add)
todo_list_parser = todo_subparsers.add_parser('list')
- todo_list_parser.add_argument('--todo-template', help="Template for printing out the event", default="{dtstart}{dtstart_passedmark} {due}{due_passed_mark} {summary}")
+ todo_list_parser.add_argument('--todo-template', help="Template for printing out the event", default="{dtstart}{dtstart_passed_mark} {due}{due_passed_mark} {summary}")
todo_list_parser.add_argument('--default-due', help="If a task has no due date set, list it with the due date set N days from today", type=int, default=14)
todo_list_parser.add_argument('--list-categories', help="Instead of listing the todo-items, list the unique categories used", action='store_true')
todo_list_parser.add_argument('--timestamp-format', help="strftime-style format string for the output timestamps", default="%Y-%m-%d (%a)")