{% for post in posts_collate %}
{% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture %} {% if current_year != '' and {{this_year}} != current_year %} {% if forloop.first != true %}</ul> {% endif %} <h2 class='year'>{{ this_year }}</h2> <ul class="post-list"> {% endif %} <li> <a class="active internal" href="{{ post.url | relative_url }}">{{ post.title }}</a> {% if post.last_updated %} <span title="{{ site.data.i18n[site.lang].last_updated }}: {{ post.last_updated | date: "%b %d, %Y" }}" class="date">{{ post.date | date: "%b %d, %Y" }}</span> {% else %} <span class="date">{{ post.date | date: "%b %d, %Y" }}</span> {% endif %} </li> {% if forloop.last %}</ul>{% endif %} {% assign current_year = {{this_year}} %}
{% endfor %}
{% assign posts_collate = nil %}