coderefinery / calendar

CodeRefinery calendar (via github pages)
https://coderefinery.github.io/calendar/
Creative Commons Zero v1.0 Universal
2 stars 2 forks source link

Update calendar with "friendly events" #32

Open samumantha opened 2 months ago

samumantha commented 2 months ago

Use workshops or community calendar: https://github.com/coderefinery/calendar/blob/main/calendars/workshops.yaml

Check other calendar entries for syntax :)

samumantha commented 1 month ago

How to do this in more sustainable way?

tpfau commented 1 month ago
rkdarst commented 1 month ago

This seems to be able to combine two ICS files, so that friendly events could be included without duplication:

a = ics.Calendar(open('out/community.ics').read())
b = ics.Calendar(urllib.request.urlopen('https://coderefinery.github.io/calendar/all.ics').read().decode())

c = ics.Calendar(events=a.events+b.events)
open('out.ics', 'w').write(c.serialize())

git-calendar could possibly be updated to do this natively (seems pretty easily: the the include would be changed to the processing of event list b above): https://github.com/coderefinery/git-calendar/blob/main/git_calendar/yaml2ics.py#L148-L153

Other things

rkdarst commented 1 month ago

The above would rely on the other organizations having a .ics feed but that seems to be the minimal we can hope for(?)

rkdarst commented 1 month ago

I think I implemented this here: https://github.com/coderefinery/git-calendar/pull/10

tpfau commented 1 month ago

Should I just merge that PR? Do I understand it correctly, that calendar will automatically pull the main branch from git-calendar and use that in the workflow, i.e. when this PR is merged, no further action on calendar (besides adding other calendars) is needed ?

tpfau commented 1 month ago

I'll put down a list of pages for training here for now: CSC - https://csc.fi/en/trainings/training-calendar/ NRIS/Sigma2 - https://www.sigma2.no/training-and-events ENCCS - https://enccs.se/events (ICS at : https://enccs.se/events-at-enccs/list/?shortcode=5210815c&ical=1) UPPMAX - https://www.uu.se/en/centre/uppmax/study/courses-and-workshops PDC - https://www.pdc.kth.se/training (ICS available via https://www.pdc.kth.se/api/icalendar/export/2.78462?l=en_GB&c=all )

tpfau commented 4 weeks ago

git-calendar now supports adding downloadable calendars (including those not as direct ics downloads, but as a download url).

Now needed: Proper ics exports from Aalto, NRIS/Sigma2/Uppmax/csc