This repository has been archived on 2020-10-14. You can view files and clone it, but cannot push or open issues or pull requests.
edt-parser/parser.py

30 lines
557 B
Python
Executable File

#!/usr/bin/env python
#-*- encoding: utf-8
import requests
from html.parser import HTMLParser
import caldav, icalendar
class GoogleSheetsParser(HTMLParser):
"""
Definition of a Google Sheets parser providing a table with each cell
and its position and size
"""
def handle_starttag(self, tag, attrs):
def handle_endtag(self, tag):
def handle_data(self, data):
# Getting the Google Sheet
# Parsing the Sheet
calParser = GoogleSheetsParser()
# Transforming the cells into events
# Pushing events to caldav server