aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2020-02-09 12:10:51 -0300
committerEuAndreh <eu@euandre.org>2020-02-09 12:10:51 -0300
commitbb84685b83d76ddcaae7e572c32a054dd9141fed (patch)
tree47b69d095fff3ee7d1bdeb99e56ad84789bc323c
parentRemove unused pastebins layout (diff)
downloadeuandre.org-bb84685b83d76ddcaae7e572c32a054dd9141fed.tar.gz
euandre.org-bb84685b83d76ddcaae7e572c32a054dd9141fed.tar.xz
Sort pastebins listing by date
-rw-r--r--_layouts/pastebins-listing.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/_layouts/pastebins-listing.html b/_layouts/pastebins-listing.html
index e829e5e..4c37c93 100644
--- a/_layouts/pastebins-listing.html
+++ b/_layouts/pastebins-listing.html
@@ -3,7 +3,8 @@ layout: default
---
<h1>Pastebins listing</h1>
<ul>
- {%- for pastebin in site.pastebins -%}
+ {% assign pastebins = site.pastebins | sort: "date" | reverse %}
+ {%- for pastebin in pastebins -%}
<li>
<a href="{{ pastebin.url | relative_url }}">{{ pastebin.title | escape }}</a> - {{ pastebin.date | date: site.t.date_format[page.lang] }}
</li>