-
Notifications
You must be signed in to change notification settings - Fork 1
/
site-map.html
41 lines (30 loc) · 876 Bytes
/
site-map.html
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
---
layout: page
title: Site Map
description: List of all pages on this site.
---
<h2>Pages</h2>
{%- assign pages = site.html_pages | where_exp:'p','p.layout!="error"' | where_exp:'p','p.layout!="redirect"' | sort:'url' %}
{% include listing.html pages=pages prefix='/' %}
{% include showcase.html %}
<h2>Categories</h2>
<ul>
{% for category in site.blog_categories %}
<li><a href="{{ category.url }}">{{ category.name }}</a></li>
{% endfor %}
</ul>
<h2>Posts</h2>
{%- assign year = site.posts | map: 'date' | first | date: '%Y' -%}
<h3>{{ year }}</h3>
<ul>
{% for post in site.posts %}
{%- assign newyear = post.date | date: '%Y' -%}
{% if newyear != year %}
</ul>
<h3>{{ newyear }}</h3>
<ul>
{% endif %}
<li><a href="{{ post.url }}">{{ post.title | markdownify | remove: '<p>' | remove: '</p>' | strip }}</a></li>
{%- assign year = newyear -%}
{% endfor %}
</ul>