summaryrefslogtreecommitdiff
path: root/layouts
diff options
context:
space:
mode:
authorNantha Sorubakanthan <nantha@mielota.com>2025-10-05 16:13:25 +0200
committerNantha Sorubakanthan <nantha@mielota.com>2025-10-05 16:13:25 +0200
commit7e526844f0bed3e12d595c75e802010991aa746b (patch)
tree5b1a786dfea2cac0905ac6945dcbba3ed3a40def /layouts
parent0850ab4fe2d83c16ad796bfab75d5d54d762ebf2 (diff)
Only show blog in the rss feed
Diffstat (limited to 'layouts')
-rw-r--r--layouts/index.xml8
1 files changed, 2 insertions, 6 deletions
diff --git a/layouts/index.xml b/layouts/index.xml
index 3af797c..6ec821f 100644
--- a/layouts/index.xml
+++ b/layouts/index.xml
@@ -1,20 +1,16 @@
{{- $authorEmail := .Site.Params.email }}
-
{{- $authorName := .Site.Params.name }}
-
{{- $pctx := . }}
{{- if .IsHome }}{{ $pctx = .Site }}{{ end }}
{{- $pages := slice }}
-{{- if or $.IsHome $.IsSection }}
{{- $pages = $pctx.RegularPages }}
-{{- else }}
-{{- $pages = $pctx.Pages }}
-{{- end }}
+{{- $pages = where $pages "Section" "blog" }}
{{- $limit := .Site.Config.Services.RSS.Limit }}
{{- if ge $limit 1 }}
{{- $pages = $pages | first $limit }}
{{- end }}
{{- printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?>" | safeHTML }}
+
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>{{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{ . }} on {{ end }}{{ .Site.Title }}{{ end }}</title>