diff options
author | eug-vs <eugene@eug-vs.xyz> | 2022-04-21 16:18:31 +0300 |
---|---|---|
committer | eug-vs <eugene@eug-vs.xyz> | 2022-04-21 16:18:31 +0300 |
commit | 73376d049e64f335b7c40c94c4d7f6fa9e06d77b (patch) | |
tree | ba760c425bc6e49483b20a49456afee9feada930 | |
parent | 3d1a2ee24442f9fe2078a60526eeb913fc59e12a (diff) | |
download | benzin-73376d049e64f335b7c40c94c4d7f6fa9e06d77b.tar.gz |
fix: correctly display title on index page
-rw-r--r-- | Makefile | 11 |
1 files changed, 9 insertions, 2 deletions
@@ -1,6 +1,8 @@ # BENZIN Makefile -BASE_URL=https://example.com +WEBSITE_URL=https://example.com +WEBSITE_TITLE="Example Website" + CONVERT=pandoc --from=gfm+emoji --to=html --section-divs --shift-heading-level-by=1 PAGE_TEMPLATE=templates/page.html @@ -42,6 +44,11 @@ tmp/%.content.html: src/%.md tmp/%.meta.title: src/%.md @mkdir -p $(@D) sed '/^#/q' $< | sed 's/#* //' > $@ + echo "| $(WEBSITE_TITLE)" >> $@ + +tmp/index.meta.title: + @mkdir -p $(@D) + echo $(WEBSITE_TITLE) > $@ $(RSS): $(BLOG_XML) $(RSS_TEMPLATE) @mkdir -p $(@D) @@ -53,7 +60,7 @@ tmp/%.xml: tmp/%.content.html tmp/%.meta.title $(RSS_ITEM_TEMPLATE) sed -i \ -e '/<item>/{' \ -e 'a <title>' -e "r tmp/$*.meta.title" -e 'a <\/title>' \ - -e "a <link>$(BASE_URL)/$*.html<\/link>" \ + -e "a <link>$(WEBSITE_URL)/$*.html<\/link>" \ -e '}' $@ $(OPENRING_FOOTER): $(OPENRING_TEMPLATE) |