forked from CHTC/chtc-website-source
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnews.html
32 lines (26 loc) · 820 Bytes
/
news.html
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
---
highlighter: none
layout: markdown-page
title: News
---
{% assign articles = site.news | sort: "date" | reverse %}
{% assign num_articles = articles.size %}
{% assign num_articles_sub_one = num_articles | minus: 1 %}
{% for article_index in (0..num_articles_sub_one) %}
<h2 class="uw-mini-bar">
{% if articles[article_index].external_url %}
<a href="{{ articles[article_index].external_url }}">
{% else %}
<a href="{{ articles[article_index].url | relative_url }}">
{% endif %}
{{ articles[article_index].title }}
</a>
</h2>
<h3 class="mt-0 text-muted">{{ articles[article_index].date | date_to_long_string }}</h3>
<p>
{{ articles[article_index].excerpt | markdownify | strip_html | markdownidfy }}
</p>
{% unless article_index == num_articles_sub_one %}
<hr/>
{% endunless %}
{% endfor %}