diff options
author | Sergio Carlavilla Delgado <carlavilla@FreeBSD.org> | 2021-05-16 10:32:57 +0000 |
---|---|---|
committer | Sergio Carlavilla Delgado <carlavilla@FreeBSD.org> | 2021-05-16 10:32:57 +0000 |
commit | a1968cbbedb7b3ac7dab38edaa28fc3eb3dec24e (patch) | |
tree | 581b18cb457c14238e8cc05e559fe6b446815571 | |
parent | 23babb1f54c9bb09d3ed8b97092a4f37d240bf7c (diff) | |
download | doc-a1968cbbedb7b3ac7dab38edaa28fc3eb3dec24e.tar.gz doc-a1968cbbedb7b3ac7dab38edaa28fc3eb3dec24e.zip |
RSS feed Security Advisories and Errata notices show first 10 entries
Show only the fist 10 entries in the security RSS feed like the
old website
PR: 253011
Submitted by: yasu (at) utahime.org
-rw-r--r-- | website/themes/beastie/layouts/security/security.rss.xml | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/website/themes/beastie/layouts/security/security.rss.xml b/website/themes/beastie/layouts/security/security.rss.xml index 0e0a9801f6..bace49147d 100644 --- a/website/themes/beastie/layouts/security/security.rss.xml +++ b/website/themes/beastie/layouts/security/security.rss.xml @@ -22,17 +22,22 @@ <guid>{{ absLangURL ($.Site.BaseURL) }}security/advisories/{{ .name }}.asc</guid> <pubDate>{{ .date }}</pubDate> </item> + {{ $securityCounter = add $securityCounter 1 }} {{ end }} {{ end }} {{ end }} {{ with .Site.Data.security.advisories }} + {{ $advisoriesCounter := 0 }} {{ range (sort .advisories "date" "desc") }} + {{ if lt $advisoriesCounter 10 }} <item> <title>{{ .name }}</title> <link>{{ absLangURL ($.Site.BaseURL) }}/security/advisories/{{ .name }}.asc</link> <guid>{{ absLangURL ($.Site.BaseURL) }}/security/advisories/{{ .name }}.asc</guid> <pubDate>{{ .date }}</pubDate> </item> + {{ $advisoriesCounter = add $advisoriesCounter 1 }} + {{ end }} {{ end }} {{ end }} </channel> |