cal: add dk account
parent
e506793ddc
commit
43c0ad1608
10
bin/cal.py
10
bin/cal.py
|
@ -18,10 +18,10 @@ if not Path("~/.gcalcli_oauth").expanduser().exists():
|
||||||
|
|
||||||
i3 = i3ipc.Connection()
|
i3 = i3ipc.Connection()
|
||||||
|
|
||||||
|
accounts = ["yorickvanpelt@gmail.com", "yorick.vanpelt@tweag.io", "yorick@datakami.nl"]
|
||||||
|
|
||||||
gcal = GoogleCalendarInterface(
|
gcal = GoogleCalendarInterface(
|
||||||
cal_names=parse_cal_names(["yorickvanpelt@gmail.com", "yorick.vanpelt@tweag.io"]),
|
cal_names=parse_cal_names(accounts),
|
||||||
config_folder=None, refresh_cache=False,
|
config_folder=None, refresh_cache=False,
|
||||||
use_cache=True,
|
use_cache=True,
|
||||||
ignore_started=False,
|
ignore_started=False,
|
||||||
|
@ -38,9 +38,9 @@ events = gcal._search_for_events(start=datetime.now(tzlocal()), end=start_date +
|
||||||
opt = sys.argv[1]
|
opt = sys.argv[1]
|
||||||
|
|
||||||
def authuser(evt):
|
def authuser(evt):
|
||||||
if evt["gcalcli_cal"]["id"] == "yorickvanpelt@gmail.com":
|
try:
|
||||||
return 0
|
return accounts.index(evt["gcalcli_cal"]["id"])
|
||||||
else:
|
except ValueError:
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
def tooltip(evt):
|
def tooltip(evt):
|
||||||
|
|
Loading…
Reference in New Issue