From 0fa4566d17c720220423e897b561efb2df399ba0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Lehmann?= Date: Mon, 22 Dec 2014 11:03:22 +0100 Subject: [PATCH] add tags page --- _config.yml | 1 + tags.md | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 tags.md diff --git a/_config.yml b/_config.yml index d79221b..99c8bc8 100644 --- a/_config.yml +++ b/_config.yml @@ -32,5 +32,6 @@ defaults: values: layout: page comments: true + tags: code # Custom vars diff --git a/tags.md b/tags.md new file mode 100644 index 0000000..660500b --- /dev/null +++ b/tags.md @@ -0,0 +1,20 @@ +--- +layout: page +title: Tags +--- + +{% capture tags %} + {% for tag in site.tags %} + {{ tag[0] }} + {% endfor %} +{% endcapture %} +{% assign sortedtags = tags | split:' ' | sort %} + +{% for tag in sortedtags %} +# {{ tag }} + +{% for post in site.tags[tag] %} +* {{ post.date | date_to_string }} » [{{ post.title }}]({{ post.url }}) +{% endfor %} + +{% endfor %}