Closed sweth closed 1 month ago
I believe you have the "--calendar" option in the wrong position. You can see this from the error where it says "...invalid get_time_from_str value: '--calendar=gcalcli test'
". Notice that the error references the complete string '--calendar=gcalcli test'
because you're effectively passing that whole string as the start
timestamp. I made this same mistake a couple of times while typing out commands. It should be before the sub-command "agenda" like this "gcalcli --calendar="$CAL" agenda
...". So what you should have is:
(gcalcli --config-folder ~/etc/gcalcli list | grep gcal ; for CAL in gcalcli-test "gcalcli test" ; do echo "$CAL" ; gcalcli --config-folder ~/etc/gcalcli --calendar="$CAL" agenda ; done)
Hope this clears things up 👍
I merged #698 as a quick fix to make the error more self-diagnosing, and filed #697 to consider making the order-dependent parsing for --calendar
more robust.
The CLI arg to specify a calendar appears to be misparsed and treated as a start time if the calendar name contains a space. I've tried every variation I can think of to escape the space (after the necessary quoting for the shell) but nothing seems to work.