Skip to content

Commit af2cb1d

Browse files
authored
Merge pull request #34 from johnny9/ical
Add template for calender.ics
2 parents a10a6b0 + 0e563bf commit af2cb1d

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

assets/calendar.ics

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
layout: null
3+
permalink: /calendar.ics
4+
---
5+
BEGIN:VCALENDAR
6+
VERSION:2.0
7+
PRODID:-//TriangleBitDevs.org//Event Calendar//EN
8+
CALSCALE:GREGORIAN
9+
10+
{% assign events = site.posts | where: "add_to_calendar", true %}
11+
{% for event in events %}
12+
BEGIN:VEVENT
13+
UID:{{ event.id }}
14+
DTSTAMP:{{ "now" | date: "%Y%m%dT%H%M%SZ" }}
15+
DTSTART:{{ event.start | date: "%Y%m%dT%H%M%SZ" }}
16+
DTEND:{{ event.end | date: "%Y%m%dT%H%M%SZ" }}
17+
SUMMARY:{{ event.title | escape }}
18+
DESCRIPTION:{{ event.description | strip_newlines | escape }}
19+
LOCATION:{{ event.location | escape }}
20+
END:VEVENT
21+
{% endfor %}
22+
23+
END:VCALENDAR

0 commit comments

Comments
 (0)