forked from paperswithcode/ai-deadlines
-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathnewsletter.xml
More file actions
50 lines (50 loc) · 2.99 KB
/
newsletter.xml
File metadata and controls
50 lines (50 loc) · 2.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
---
permalink: /newsletter.xml
---
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
>
<channel>
<title>{{ site.title | xml_escape }} Newsletter</title>
<description>Python conference CFP deadlines coming up in the next 14 days</description>
<link>{{ site.url }}</link>
<atom:link href="{{ site.url }}{{ site.baseurl }}/newsletter.xml" rel="self" type="application/rss+xml" />
<language>en-US</language>
<lastBuildDate>{{ site.time | date_to_rfc822 }}</lastBuildDate>
<generator>Jekyll v{{ jekyll.version }}</generator>
{%- assign today = site.time | date: "%s" | plus: 0 -%}
{%- assign horizon = site.time | date: "%s" | plus: 1209600 -%}
{%- assign taglines = "yes, your weird side project counts.|first-timers especially welcome.|got a Python story worth telling?|your debugging war stories are gold.|submit before you talk yourself out of it.|that thing you fixed at 2am? talk material.|the niche you think is too niche? it isn't.|lurkers, this is your sign.|polish optional. submit anyway.|the talk you wish existed? write it.|your maintainer rants are speaker material.|the conference is just people who said yes." | split: "|" -%}
{%- assign shuffled = taglines | sample: taglines.size -%}
{%- assign emitted = 0 -%}
{%- for conf in site.data.conferences -%}
{%- if conf.cfp_ext -%}
{%- assign cfp = conf.cfp_ext -%}
{%- else -%}
{%- assign cfp = conf.cfp -%}
{%- endif -%}
{%- if cfp != "TBA" and cfp != "Cancelled" and cfp != "None" -%}
{%- assign cfp_epoch = cfp | date: "%s" | plus: 0 -%}
{%- if cfp_epoch >= today and cfp_epoch <= horizon -%}
{%- assign idx = emitted | modulo: shuffled.size -%}
{%- assign tagline = shuffled[idx] -%}
{%- assign today_midnight = site.time | date: "%Y-%m-%d" | date: "%s" | plus: 0 -%}
{%- assign days_until = cfp_epoch | minus: today_midnight | divided_by: 86400 %}
<item>
<title>{{ conf.conference | xml_escape }} {{ conf.year }}</title>
<link>{{ site.url }}{{ site.baseurl }}/conference/{{ conf.conference | slugify: "latin" }}-{{ conf.year }}/</link>
<guid isPermaLink="false">{{ conf.conference | slugify: "latin" }}-{{ conf.year }}</guid>
<pubDate>{{ site.time | date_to_rfc822 }}</pubDate>
<dc:creator>{{ site.title | xml_escape }}</dc:creator>
<category>{{ conf.sub }}</category>
<description><![CDATA[<p>📍 {{ conf.place | xml_escape }} · 📅 {% translate_file dates/pretty_dates.html start=conf.start end=conf.end %}</p><p>✍ CfP closes {% translate_file dates/pretty_dates.html start=cfp end=cfp %} — {{ tagline }}</p>]]></description>
</item>
{%- assign emitted = emitted | plus: 1 -%}
{%- endif -%}
{%- endif -%}
{%- endfor %}
</channel>
</rss>