Skip to content

Utilities in Python3 to fetch the KCL Timetable for a user, or export it as iCalendar (*.ics for Google or Apple)!

Notifications You must be signed in to change notification settings

finwarman/kcl-timetable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

kcl-timetable (kcl.py & kclical.py)

Tools for viewing and exporting your KCL timetable.

For Python3 - To install dependencies paste the following in your terminal:

pip3 install crayons
pip3 install requests
pip3 install keyring
pip3 install icalendar

View timetable in terminal: (kcl.py)

python3 /[path]/[to]/kcl.py

Log in with your k-number and password - your credentials are stored locally for the next time you run it.

To add as a terminal command, add it as an alias, e.g. for macOS: Edit ~/.bash_profile, with sudo nano ~/.bash_profile

then add the the line

alias timetable='python3 '/[path]/[to]/kcl.py'


kcl.py timetable fetch


iCalendar export: (kclical.py)

To export your timetable (for the next 60 days) as a .ics file for import in Google and Apple Calendars, run the following script in terminal:

python3 /[path]/[to]/kclical.py

Log in with your k-number and password - your password will be stored locally and securely in the keyring. If you mistype your login, simply delete the 'knumber.fin' file in the script directory and log in again.

The calendar is exported to course_schedule.ics in the script directory.

kclical.py calendar export

About

Utilities in Python3 to fetch the KCL Timetable for a user, or export it as iCalendar (*.ics for Google or Apple)!

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages