diff options
author | eug-vs <eugene@eug-vs.xyz> | 2022-04-21 06:02:21 +0300 |
---|---|---|
committer | eug-vs <eugene@eug-vs.xyz> | 2022-04-21 06:02:21 +0300 |
commit | 691fa34413ebae101b6fd714158bdcb976abf87c (patch) | |
tree | 01607361b3d21c77348c3e2adf37805813e93cff | |
parent | 2c25e0a927ef940561609314d0896ccf13d90ae6 (diff) | |
download | benzin-691fa34413ebae101b6fd714158bdcb976abf87c.tar.gz |
feat: add links to RSS feed
-rw-r--r-- | Makefile | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -1,12 +1,14 @@ # BENZIN Makefile +BASE_URL=https://example.com + PANDOC_ARGS=--from=gfm+emoji --to=html --section-divs HEADER=templates/header.html OPENRING_TEMPLATE=templates/openring.html RSS=out/blog/index.xml OPENRING_FOOTER=tmp/openring.html -OPENRING_ARGS=-s https://eug-vs.xyz/blog/index.xml +OPENRING_ARGS=-s https://eug-vs.xyz/blog/index.xml -s https://drewdevault.com/blog/index.xml BLOG_SOURCES=$(wildcard src/blog/*.md) SOURCES=$(wildcard src/*.md) $(BLOG_SOURCES) @@ -30,16 +32,16 @@ tmp/%.content.html: src/%.md pandoc $(PANDOC_ARGS) $< > $@ $(RSS): $(BLOG_XML) - @echo $@ + @mkdir -p $(@D) @echo '<rss version="2.0"><channel>' > $@ - @echo "<title>TODO</title><link>TODO</link><description>TODO</description>" >> $@ + @echo "<title>TODO</title><link>$(BASE_URL)</link><description>TODO</description>" >> $@ @echo "<lastBuildDate>$$(date --rfc-email)</lastBuildDate>" >> $@ cat $^ >> $@ @echo '</channel></rss>' >> $@ tmp/%.xml: tmp/%.content.html @echo '<item>' > $@ - @echo " <link>TODO</link>" >> $@ + @echo " <link>$(BASE_URL)/$*.html</link>" >> $@ @echo " <pubDate>TODO</pubDate>" >> $@ @echo " <title>TODO</title>" >> $@ @echo " <description><![CDATA[" >> $@ |