{% extends "_layout/base.html" %} {% block title %} Archives {% endblock %} {% block content %} {% for post in posts %} {% endfor %} {% set this_year = 0 %} {% for post in posts %} {% set this_month = post.pub_time.strftime('%b') %} {% if this_year != post.pub_time.strftime('%Y') %} {% set this_year = post.pub_time.strftime('%Y') %}

{{ this_year }}

{% else %} {% endif %}

{{ post.pub_time.strftime('%b %d') }} , {% for category in post.categories %}{{ category }} {% endfor %}

{{ post.title }}

{% endfor %} {% endblock %}