Skip to content

Commit b3b428d

Browse files
authored
Pycon liquid to jinja (#705)
* Add time to date field * Update from Liquid to Jinja templating
1 parent d0cd2d0 commit b3b428d

File tree

33 files changed

+216
-87
lines changed

33 files changed

+216
-87
lines changed

_layouts/_includes/latest-posts.html

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,43 @@
1-
{%- if page.list_title -%}
2-
<h2 class="post-list-heading">{{ page.list_title }}</h2>
3-
{% endif %}
1+
2+
{% block content %}
3+
{% for page in pages %}
4+
{%- if page.list_title -%}
5+
<h2 class="post-list-heading">{{ list_title }}</h2>
6+
{% endif %}
47
<article class="post-list">
58
<div>
69
<h3>
7-
<a class="" href="{{ post.url }}"> {{ post.title | escape }} </a>
10+
<a class="" href="{{ url }}"> {{ title | escape }} </a>
811
</h3>
9-
<p>{{ post.date }}</p>
12+
<p>{{ date }}</p>
1013
{%- if site.show_excerpts -%}
11-
<p class="post-description" style="margin-bottom: 2rem">{{ post.description}}</p>
14+
<p class="post-description" style="margin-bottom: 2rem">{{ description}}</p>
1215
</div>
1316
</article>
1417

1518
<div class="pager">
1619
<ul class="pagination">
1720
{%- if paginator.previous_page %}
18-
<li><a href="{{ paginator.previous_page_path | relative_url }}" class="previous-page">{{ paginator.previous_page }}</a></li>
21+
<li><a href="{{ paginator.previous_page_path | relative_url }}" class="previous-page">{{ paginator.previous_page
22+
}}</a></li>
1923
{%- else %}
20-
<li><div class="pager-edge"></div></li>
24+
<li>
25+
<div class="pager-edge"></div>
26+
</li>
2127
{%- endif %}
22-
<li><div class="current-page">{{ paginator.page }}</div></li>
28+
<li>
29+
<div class="current-page">{{ paginator.page }}</div>
30+
</li>
2331
{%- if paginator.next_page %}
2432
<li><a href="{{ paginator.next_page_path | relative_url }}" class="next-page">{{ paginator.next_page }}</a></li>
2533
{%- else %}
26-
<li><div class="pager-edge"></div></li>
34+
<li>
35+
<div class="pager-edge"></div>
36+
</li>
2737
{%- endif %}
2838
</ul>
2939
</div>
3040
{%- endif %}
41+
42+
{% endfor %}
43+
{% endblock %}

_layouts/_includes/newsletter_form.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<article>
2-
<h3>{{include.newsletter_title}}</h3>
2+
<h3>{{newsletter_title}}</h3>
33
<form action="https://buttondown.email/api/emails/embed-subscribe/black-python-devs" method="post" target="popupwindow" onsubmit="window.open('https://buttondown.email/black-python-devs', 'popupwindow')">
44
<fieldset role="group">
55
<input type="email" name="email" id="bd-email" placeholder="Enter your email" />

_layouts/_includes/partnerships.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ <h2>Partnerships</h2>
44
<p>We're happy to share with you our proud sponsors who offer their products at discounted rates and a portion of proceeds go to support Black Python Devs!</p>
55

66
<div class="grid">
7-
{% for partner in site.data.partnerships %}
7+
{% for partner in partnerships %}
88
<article>
99
<div class="grid">
1010
<div>
11-
<img src="{{partner.logo}}" alt="{{partner.name}} Logo" style="max-height: 14em" />
11+
<img src="{{logo}}" alt="{{name}} Logo" style="max-height: 14em" />
1212
</div>
1313
<div>
14-
<h3><a href="{{partner.url}}">{{ partner.name }}</a></h3>
15-
<p>{{ partner.description }}</p>
16-
<a href="{{ partner.url }}">Learn more</a>
14+
<h3><a href="{{url}}">{{ name }}</a></h3>
15+
<p>{{ description }}</p>
16+
<a href="{{ url }}">Learn more</a>
1717
</div>
1818
</div>
1919
</article>

_layouts/post.html

Lines changed: 27 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,41 @@
1-
---
2-
layout: default
3-
---
1+
{% extends "default.html" %}
2+
43
<section>
5-
{%- if page.featured_image -%}
6-
<div class="hero-banner">
7-
<img src="{{page.featured_image}}" class="featured-image" alt="author image">
8-
</div>
9-
{%- else -%}
10-
<div class="hero-banner">
11-
<img src="/assets/images/bpd_stacked.png" class="featured-image" alt="Hero image">
12-
</div>
13-
{%- endif -%}
4+
{%- if featured_image -%}
5+
<div class="hero-banner">
6+
<img src="{{ featured_image }}" class="featured-image" alt="author image">
7+
</div>
8+
{%- else -%}
9+
<div class="hero-banner">
10+
<img src="/assets/images/bpd_stacked.png" class="featured-image" alt="Hero image">
11+
</div>
12+
{%- endif -%}
1413
<article class="post h-entry" itemscope itemtype="http://schema.org/BlogPosting">
1514
<header class="post-header">
16-
<h1 class="post-title p-name" itemprop="name headline">{{ page.title | escape }}</h1>
15+
<h1 class="post-title p-name" itemprop="name headline">{{ title|e }}</h1>
1716
<p class="post-meta">
18-
{%- assign date_format = site.bpdevs.date_format | default: "%b %-d, %Y" -%}
19-
<time class="dt-published" datetime="{{ page.date | date_to_xmlschema }}" itemprop="datePublished">
20-
{{ page.date | date: date_format }}
21-
</time>
22-
{%- if page.modified_date -%}
23-
~
24-
{%- assign mdate = page.modified_date | date_to_xmlschema -%}
25-
<time class="dt-modified" datetime="{{ mdate }}" itemprop="dateModified">
26-
{{ mdate | date: date_format }}
27-
</time>
28-
{%- endif -%}
29-
{%- if page.author -%}
30-
• {% for author in page.author %}
17+
{%- for author in author %}
3118
<span itemprop="author" itemscope itemtype="http://schema.org/Person">
32-
<span class="p-author h-card" itemprop="name">{{ author }}</span></span>
33-
{%- if forloop.last == false %}, {% endif -%}
34-
{% endfor %}
35-
{%- endif -%}
19+
<span class="p-author h-card" itemprop="name">{{ author }}</span>
20+
</span>
21+
{%- if not loop.last %}, {% endif -%}
22+
{%- endfor -%}
23+
3624
</p>
3725
</header>
3826
<div class="post-content e-content" itemprop="articleBody">
3927
{{ content }}
4028
</div>
41-
<a class="u-url" href="{{ page.url | relative_url }}" hidden></a>
4229
</article>
4330
</section>
4431

45-
{% assign author = site.data.authors | where:"name", page.author | first %}
32+
{% set author = authors | selectattr("name", "equalto", author) | first %}
4633
<section>
47-
{% if author.bio %}
48-
<hr />
49-
<h3>About {{author.name}}</h3>
50-
<p>{{author.bio}}</p>
51-
</section>
52-
{% endif %}
34+
{% if author and author.bio %}
35+
<hr />
36+
<h3>About {{author.name}}</h3>
37+
<p>{{author.bio|e}}</p>
38+
</section>
39+
{% endif %}
40+
41+
{% endblock %}

_posts/2023-10-20-djangoconus.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2023-10-20
2+
date: 2023-10-20 08:00:00
33
description: Join us for a behind-the-scenes look at DjangoCon US 2023, where diversity
44
and inclusion came together to shape a powerful community of Python developers.
55
lang: en

_posts/2023-11-11-what-is-the-us-conference-city-diversity-metric.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2023-11-11
3+
date: 2023-11-11 08:00:00
44
description: Discover how the US Conference Diversity Metric can inform your event's
55
location and create a more inclusive experience for attendees, with expert analysis
66
from Jay Miller.

_posts/2023-11-13-black-python-devs-represent-in-dsf-elections.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2023-11-13
3+
date: 2023-11-13 08:00:00
44
description: Find out how the growing presence of Black Python Developers is shaping
55
the future of diversity in the tech industry through the DSF Elections.
66
lang: en

_posts/2023-12-14-dawn-wages-sarah-abderemane-and-djangonaut-space-awarded-the-malcolm-tredinnick-memorial-prize.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2023-12-14
3+
date: 2023-12-14 08:00:00
44
description: Discover how the innovative team at Djangonaut Space is making a lasting
55
impact on the Django community with sustainable initiatives and groundbreaking projects.
66
lang: en

_posts/2023-12-14-sarah-abderemane-selected-to-the-django-software-foundation-board.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2023-12-14
3+
date: 2023-12-14 08:00:00
44
description: Discover how Sarah Abderemane's selection to the Django Software Foundation
55
Board of Directors is a significant milestone for the thriving Black Python Devs
66
community.

_posts/2024-01-12-black-python-devs-is-sponsoring-pytexas.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2024-01-12
3+
date: 2024-01-12 08:00:00
44
description: Discover how Black Python Devs is supporting PyTexas, a premier regional
55
Python conference in Austin, TX, and learn about opportunities to attend for free
66
through ticket giveaways and speaker selection.

_posts/2024-01-25-marlene-mhangami-recognized-as-python-fellow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-01-25
2+
date: 2024-01-25 08:00:00
33
description: Meet Marlene Mhangami, a trailblazing leader in the Python community
44
recognized for her exceptional contributions as PSF Chair and DEI Working Group
55
member, now highlighted as a Q3 2023 Python Fellow.

_posts/2024-03-13-pycon-us-announcement.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-03-13
2+
date: 2024-03-13 08:00:00
33
description: Explore how Black Python Devs is shaping the future of the Python community
44
through a range of events and activities at PyCon US.
55
lang: en

_posts/2024-05-03-pycon_ng_2024.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-05-03
2+
date: 2024-05-03 08:00:00
33
description: Discover how Black Python Devs is empowering the next generation of developers
44
through its partnership with PyCon Nigeria 2024 and learn about exclusive opportunities
55
for students.

_posts/2024-05-17-non-profit-announcement.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-05-16
2+
date: 2024-05-16 08:00:00
33
description: Discover how a historic partnership between two influential organizations
44
is revolutionizing tech diversity and innovation in the open-source world.
55
featured_image: /assets/images/BPD_STACKED_featured.png

_posts/2024-05-22-why-we-use-colored-and-coloured.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-05-22
2+
date: 2024-05-22 08:00:00
33
description: Join us as we explore a nuanced approach to inclusive language, examining
44
the complexities of terms like "Black", "Colored", and "coloured" in describing
55
our community members.

_posts/2024-05-25-abigail-mesrenyame-dogbe-wins-inaugural-outstanding-pylady-award.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Anotida Expected Msiiwa
3-
date: 2024-01-25
3+
date: 2024-01-25 08:00:00
44
description: Meet Abigail Mesrenyame Dogbe, a dedicated member of Black Python Devs
55
and recipient of the Inaugural Outstanding PyLady award, whose inspiring contributions
66
to the open-source community are empowering women in STEM.

_posts/2024-07-03-black-python-devs-running-for-2024-PSF-Board.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Anotida Expected Msiiwa
3-
date: 2024-07-03
3+
date: 2024-07-03 08:00:00
44
description: Join us in learning about four exceptional Black Python developers who
55
are shaping the future of the Python community and running for a crucial role on
66
the Python Software Foundation Board.

_posts/2024-07-20-black-python-devs-partners-with-pyohio.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Anotida Expected Msiiwa
3-
date: 2024-07-20
3+
date: 2024-07-20 08:00:00
44
description: Discover how Black Python Devs is teaming up with PyOhio to create a
55
more inclusive and diverse community, supporting and amplifying the voices of Black
66
developers in Ohio and beyond.

_posts/2024-08-15-python-morsels-black-python-devs-high-five.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2024-08-15
3+
date: 2024-08-15 08:00:00
44
description: Discover how to kickstart your Python skills with a comprehensive 10-week
55
course, featuring daily exercises, community support, and real-world applications
66
- now available with an exclusive $30 off offer.

_posts/2024-08-16-talkpython-training-partnership.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2024-08-16
3+
date: 2024-08-16 08:00:00
44
description: Learn how TalkPython Training's new partnership with Black Python Devs
55
is driving greater diversity and benefiting learners through a unique opportunity
66
to support both your education and the community.

_posts/2024-09-09-oreilly-partnership.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2024-09-09
3+
date: 2024-09-09 08:00:00
44
description: Get the inside scoop on O'Reilly Media's innovative partnership with
55
Black Python Devs and discover how it's revolutionizing access to high-quality learning
66
resources for the Black Python community.

_posts/2024-10-13-black-python-devs-ghana-event.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Abigail Afi Gbadago
3-
date: 2024-10-13
3+
date: 2024-10-13 08:00:00
44
description: Discover how Ghanaian developers turned their passion for coding into
55
a career with inspiring stories of perseverance and innovation in Python.
66
featured_image: /assets/images/bpd_ghana_connect1.webp

_posts/2024-10-19-black-python-devs-leadership-summit.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Abigail Afi Gbadago
3-
date: 2024-10-19
3+
date: 2024-10-19 08:00:00
44
description: Join Abigail Afi Gbadago and other leaders at the highly successful Black
55
Python Devs Leadership Summit as they shared insights on succession planning, mental
66
health, and leadership skills in a day of engaging talks and interactive sessions.

_posts/2024-10-25-pycon-ug-2024.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Tobias Thomas (Toe•bias HT)
3-
date: 2024-10-25
3+
date: 2024-10-25 08:00:00
44
description: Discover the inspiring stories of Uganda's next generation African Python
55
developers who attended PyconUG 2024 and learn about their experiences in a vibrant
66
tech community.

_posts/2024-10-29-dsf-candidates-2025.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Jay Miller
3-
date: 2024-10-29
3+
date: 2024-10-29 08:00:00
44
description: Discover how a new generation of Black Python Developers is shaping the
55
future of Django and the global tech community, and learn about their inspiring
66
stories and impact on the world.

_posts/2024-11-02-black-python-devs-pyho-2024.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
author: Kafui Alordo
3-
date: 2024-11-02
3+
date: 2024-11-02 08:00:00
44
description: Discover how Black Python Devs is redefining the future of Python's open
55
source ecosystem by creating a safe and inclusive space for underrepresented developers.
66
featured_image: /assets/images/bpd_pyho_2024.jpg

_posts/2024-12-02-typefully-support-bpd.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-12-02
2+
date: 2024-12-02 08:00:00
33
description: We're happy to announce that Typefully is sponsoring Black Python Devs.
44
lang: en
55
layout: post

_posts/2024-12-16-bpd-announces-regional-executors.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
date: 2024-12-16
2+
date: 2024-12-16 08:00:00
33
description: Black Python Devs is announcing a major change to leadership at the top
44
level.
55
lang: en

_posts/2025-01-08-2024-recap.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: 2024 Recap and What to Expect in 2025
33
author: Jay Miller
44
description: Our executor gives a brief recap of 2024 and a glimpse into the global goals for Black Python Devs.
5-
date: 2025-01-08
5+
date: 2025-01-08 08:00:00
66
layout: post
77
lang: en
88
---

_posts/2025-04-26-lessons-learned-from-our-leaders.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Reflecting on the last two years with our BPD Leaders
33
author: Jay Miller
44
description:
5-
date: 2025-04-26
5+
date: 2025-04-26 08:00:00
66
layout: post
77
lang: en
88
---

_posts/2025-04-28-baovola-marie-anna-added-to-bpd-council.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: BAOVOLA Marie Anna Added to BPD Council
3-
date: 2025-04-28
3+
date: 2025-04-28 08:00:00
44
author: Jay Miller
55
description: The BPD Council has recognized the work of BAOVOLA Marie Anna and invited her to join the Council.
66
featured_image: /assets/images/baovola-jay-pg-day-chi-2025.webp

0 commit comments

Comments
 (0)