mirror of
https://github.com/b4tman/sync_ics2gcal
synced 2026-06-27 05:46:12 +03:00
+ default credentials support
https://googleapis.dev/python/google-auth/latest/reference/google.auth.html#google.auth.default https://developers.google.com/identity/protocols/application-default-credentials
This commit is contained in:
@@ -34,14 +34,13 @@ def main():
|
||||
|
||||
calendarId = config['calendar']['google_id']
|
||||
ics_filepath = config['calendar']['source']
|
||||
srv_acc_file = config['service_account']
|
||||
|
||||
start = get_start_date(config['start_from'])
|
||||
|
||||
converter = CalendarConverter()
|
||||
converter.load(ics_filepath)
|
||||
|
||||
service = GoogleCalendarService.from_srv_acc_file(srv_acc_file)
|
||||
service = GoogleCalendarService.from_config(config)
|
||||
gcalendar = GoogleCalendar(service, calendarId)
|
||||
|
||||
sync = CalendarSync(gcalendar, converter)
|
||||
|
||||
Reference in New Issue
Block a user