-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patharchives.html
More file actions
46 lines (42 loc) · 1.11 KB
/
archives.html
File metadata and controls
46 lines (42 loc) · 1.11 KB
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
36
37
38
39
40
41
42
43
44
45
46
---
layout: page
---
<ul>
{% for post in site.posts %}
<li>
{{ post.date | date_to_string }}
<a href="{{ post.url }}">{{ post.title }}</a>
</li>
{% endfor %}
</ul>
<!---
---
layout: page
title: Archives
permalink: /archives/
order: 3
share: false
---
{% 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>-->