portfolio/_layouts/archive.html

29 lines
888 B
HTML

---
layout: default
---
<ul class="posts-container">
{% for post in site.posts %}
{% unless post.next %}
<h3>{{ post.date | date: '%Y' }}</h3>
{% else %}
{% capture year %}{{ post.date | date: '%Y' }}{% endcapture %}
{% capture nyear %}{{ post.next.date | date: '%Y' }}{% endcapture %}
{% if year != nyear %}
<hr />
<h3>{{ post.date | date: '%Y' }}</h3>
{% endif %}
{% endunless %}
<li itemscope>
<div class="post-tags">
<a href="{{ site.github.url }}{{ post.url }}">{{ post.title }}</a>
{% for tag in post.tags %}
<div class="{{ tag }}">{{ tag }}</div>
{% endfor %}
</div>
<p>{{ post.content | strip_html }}</p>
<p class="post-date"><span><i class="fa fa-calendar" aria-hidden="true"></i> {{ post.date | date: "%B %-d" }}</span></p>
</li>
{% endfor %}
</ul>