diff options
| author | Mole Shang <135e2@135e2.dev> | 2026-09-02 15:49:49 +0800 |
|---|---|---|
| committer | Mole Shang <135e2@135e2.dev> | 2026-09-02 15:49:49 +0800 |
| commit | 23d62aaa39dae753d39dcd596b962ccc1c5cdb36 (patch) | |
| tree | 269670883636ee9adb47a123acd69abd2d6522a0 /templates/archives.html | |
| parent | a582b6ef76bfb79744716f5cdfafff8c41861ec9 (diff) | |
| download | Seje2-23d62aaa39dae753d39dcd596b962ccc1c5cdb36.tar.gz Seje2-23d62aaa39dae753d39dcd596b962ccc1c5cdb36.tar.bz2 Seje2-23d62aaa39dae753d39dcd596b962ccc1c5cdb36.zip | |
templates: migrate to zola 0.23main
tera v1->v2
https://github.com/getzola/zola/issues/3235
https://github.com/Keats/tera/blob/master/MIGRATION.md
Diffstat (limited to 'templates/archives.html')
| -rw-r--r-- | templates/archives.html | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/templates/archives.html b/templates/archives.html index e691c86..79feb9d 100644 --- a/templates/archives.html +++ b/templates/archives.html @@ -5,11 +5,8 @@ <ul class="post-archive"> {# Group the posts by year #} {% set map = get_section(path="_index.md") | get(key="pages") | group_by(attribute="year") %} - {% set_global years = [] %} {# Convert the years map to an array (since maps do not have determined order) #} - {% for year, ignored in map %} - {% set_global years = years | concat(with=year) %} - {% endfor %} + {% set_global years = [year for year, ignored in map] %} {% for year in years | sort | reverse %} <div class="years"> |
