aboutsummaryrefslogtreecommitdiff
path: root/themes
diff options
context:
space:
mode:
authortdro <tdro@noreply.example.com>2022-08-10 01:19:33 -0400
committertdro <tdro@noreply.example.com>2022-08-10 01:19:33 -0400
commit64157920c5dfca820d7f6b4c4a8a301f4ebc8c2c (patch)
treed2af90cc3ec6354a1b61892b41df541e12d1eb46 /themes
parenta2753213c7a392e3f5d937c67580c356f29d71ba (diff)
downloadcanory-64157920c5dfca820d7f6b4c4a8a301f4ebc8c2c.tar.gz
canory-64157920c5dfca820d7f6b4c4a8a301f4ebc8c2c.tar.bz2
canory-64157920c5dfca820d7f6b4c4a8a301f4ebc8c2c.zip
themes/default/layouts/partials/generate-feeds: Don't strip periods
Clarify file variable.
Diffstat (limited to 'themes')
-rw-r--r--themes/default/layouts/partials/function-strip-urlchars.html1
-rw-r--r--themes/default/layouts/partials/generate-feeds.html9
2 files changed, 4 insertions, 6 deletions
diff --git a/themes/default/layouts/partials/function-strip-urlchars.html b/themes/default/layouts/partials/function-strip-urlchars.html
index 252d496..bc88d38 100644
--- a/themes/default/layouts/partials/function-strip-urlchars.html
+++ b/themes/default/layouts/partials/function-strip-urlchars.html
@@ -20,7 +20,6 @@
replaceRE "\\+" "" |
replaceRE "$" "" |
replaceRE "," "" |
- replaceRE "\\." "" |
replaceRE "<" "" |
replaceRE ">" "" |
replaceRE "#" "" |
diff --git a/themes/default/layouts/partials/generate-feeds.html b/themes/default/layouts/partials/generate-feeds.html
index 76186fd..b8e7f75 100644
--- a/themes/default/layouts/partials/generate-feeds.html
+++ b/themes/default/layouts/partials/generate-feeds.html
@@ -206,10 +206,9 @@
-}}
{{- $template := resources.Get "templates/markdown-feed.yaml" -}}
- {{- $name := print (delimit (first 8 (split (.FeedTitle | urlize) "-")) "-" | humanize | urlize) "-" (.FeedLink | sha256 | truncate 8 "") -}}
- {{- $name = partial "function-strip-urlchars.html" $name -}}
-
- {{- $path := print "/data/generates/content/" $author.user "/feeds/" $name ".md" -}}
+ {{- $file := print (delimit (first 8 (split (.FeedTitle | urlize) "-")) "-" | humanize | urlize) "-" (.FeedLink | sha256 | truncate 8 "") -}}
+ {{- $file = partial "function-strip-urlchars.html" $file -}}
+ {{- $path := print "/data/generates/content/" $author.user "/feeds/" $file ".md" -}}
{{- $description := .FeedDescriptionShort -}}
{{- if gt (len .FeedTitle) (len .FeedDescriptionShort) -}}
@@ -235,7 +234,7 @@
"link" .FeedLink
"name" .FeedName
"raw" (strings.TrimLeft "/" $path)
- "self" (print $author.user "/feeds/" $name "/")
+ "self" (print $author.user "/feeds/" $file "/")
"tags" "[rss]"
)
$template