File: archives.html

package info (click to toggle)
hisat2 2.2.1-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 19,448 kB
  • sloc: cpp: 97,109; python: 11,075; perl: 7,279; sh: 2,328; ansic: 1,458; makefile: 532; javascript: 273; java: 116
file content (35 lines) | stat: -rw-r--r-- 950 bytes parent folder | download | duplicates (3)
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
32
33
34
35
---
layout: page
title: Archives
permalink: /archives/
order: 3
share: false
hide: true
---

{% for post in site.posts %}
    {% unless post.next %}
        <h3>{{ post.date | date: '%Y' }}</h3>
        <ul>
    {% else %}
        {% assign year = post.date | date: '%Y' %}
        {% assign next_year = post.next.date | date: '%Y' %}
        {% if year != next_year %}
        </ul>
        <h3>{{ post.date | date: '%Y' }}</h3>
        <ul>
        {% endif %}
    {% endunless %}

    {% assign month = post.date | date: '%m' %}
    {% assign next_month = post.next.date | date: '%m' %}
    {% if year != next_year or month != next_month %}
    <li><a href="{{ '/search/?d=' | prepend: site.baseurl }}{{ post.date | date: '%Y-%m' }}">{{ post.date | date: '%Y/%m' }}</a></li>
    {% endif %}
{% endfor %}

{% if site.posts %}
</ul>
{% endif %}

<a class="btn" href="{{ '/archives/all/' | prepend: site.baseurl }}">{{ site.str_show_all_posts }}</a>