You are browsing as a guest. Sign up (or log in) to start making projects!

Google Classroom Calendar Sync

  • 2 Devlogs
  • 3 Total hours

This program basically takes your google classroom calendars and imports all assignments and due dates into an ICS file, which can then easily be uploaded to pretty much any calendar app that exists. You can also choose to upload it as a secret Gitub gist, where now the calendar app will automatically update as you get more assignments from your teachers. More details about the motivation and all will be in the Github readme.

Open comments for this post

1h 50m 6s logged

In these ~1.75hrs, I have done 3 things:

  1. Made the GitHub gist upload part of the app a separate command in the command line. Previously it just ran automatically with classroom-sync run if the environment variable was there.
  2. The app uses playwright, a sort of web browser simulator so that you can load websites and extract information from them using code. It only officially supports a few Linux distros (mainly Ubuntu and Fedora based I think), so I added a message to people not on those distros like myself to use a workaround.
  3. Converted the Javascript code to Typescript so that it can be maintained easier.
0
0
3
Open comments for this post

59m logged

Most of the app is done now, just need to fix some crazy edge cases, like right now, it doesn’t work if there is an event that is 2 weeks long, and cross year as well. I also need to test if the Github gist script actually works.

So here’s the flow right now:

One time setup:

  1. You run the save-session.js script, it will open a browser window
  2. Login to your school account
  3. Press enter in the terminal, the script will then save the cookies of the browser session so that it can use that to get calendar data later.

I will put more details about why I chose this methodology later in the Github readme.

To generate the *.ics file:

  1. You run the fetch-ics.js script and wait patiently. If you set the MONTHS_TO_WALK constant in the file to a fairly big number, it can take a while.
  2. The script will go through each page of the “Public URL of the Calendar” (not very public) and webscrape each event that is there. Since it is using your credentials from the One time setup, it will get all of the events, not just the public ones.
  3. Done! Now you have a classroom.ics file that you can do whatever you want with!
0
0
1

Delete project?

Are you sure you want to permanently delete this project? This action cannot be undone.

All devlogs, followers, and associated data will be removed.

Followers

Loading…