Skip to content

Commit

Permalink
Merge pull request #511 from Xm798/dev
Browse files Browse the repository at this point in the history
✨ Feat: Add Follow site challenge support in RSS feed
  • Loading branch information
Lruihao authored Oct 1, 2024
2 parents e9edbba + 566a87c commit 729c2c3
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
4 changes: 4 additions & 0 deletions hugo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -822,6 +822,10 @@ enableEmoji = true
limit = 10
# whether to show the full text content in feed.
fullText = true
# Site Challenge for Follow: https://follow.is/
[params.feed.follow]
feedId = ""
userId = ""

# FixIt 0.3.12 | NEW Custom partials config
# Custom partials must be stored in the /layouts/partials/ directory.
Expand Down
6 changes: 6 additions & 0 deletions layouts/partials/feed/rss.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@
<title>{{ .Title }}</title>
<link>{{ .Permalink }}</link>
<description>{{ .Site.Params.description | default .Site.Title }}</description>
{{- if and (.Site.Params.feed.follow.feedId) (.Site.Params.feed.follow.userId) }}
<follow_challenge>
<feedId>{{ .Site.Params.feed.follow.feedId }}</feedId>
<userId>{{ .Site.Params.feed.follow.userId }}</userId>
</follow_challenge>
{{- end }}
<generator>Hugo {{ hugo.Version }} &amp; FixIt {{ .Version }}</generator>
<language>{{ .Site.Language.LanguageCode }}</language>{{ with .Site.Params.author.email }}
<managingEditor>{{.}}{{ with $.Site.Params.author.name }} ({{ . }}){{ end }}</managingEditor>{{ end }}{{ with .Site.Params.author.email }}
Expand Down
2 changes: 1 addition & 1 deletion layouts/partials/init/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{- .Scratch.Set "version" "v0.3.13-9e9bc9ef" -}}
{{- .Scratch.Set "version" "v0.3.13-8614ed49" -}}
{{- .Scratch.Set "this" dict -}}

{{- partial "init/detection-env.html" . -}}
Expand Down

0 comments on commit 729c2c3

Please sign in to comment.