summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile9
-rw-r--r--templates/tag_link.html1
-rw-r--r--templates/tag_link_footer.html1
-rw-r--r--templates/tag_link_header.html1
4 files changed, 11 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index be6e80014..5021f9a68 100644
--- a/Makefile
+++ b/Makefile
@@ -131,7 +131,7 @@ blog/@%.html: $(TAGFILES) $(addprefix templates/,$(addsuffix .html,header tag_in
envsubst < templates/footer.html >> $@; \
-blog/%.html: $(BLOG_SRC)/%.md $(addprefix templates/,$(addsuffix .html,header article_header article_footer footer))
+blog/%.html: $(BLOG_SRC)/%.md $(addprefix templates/,$(addsuffix .html,header article_header tag_link_header tag_link tag_link_footer article_footer footer))
mkdir -p blog
TITLE="$(shell head -n1 $< | sed 's/^# \+//')"; \
export TITLE; \
@@ -148,6 +148,13 @@ blog/%.html: $(BLOG_SRC)/%.md $(addprefix templates/,$(addsuffix .html,header ar
envsubst < templates/header.html > $@; \
envsubst < templates/article_header.html >> $@; \
sed -e '/^;/d' < $< | markdown -f fencedcode >> $@; \
+ envsubst < templates/tag_link_header.html >> $@; \
+ for i in $${TAGS} ; do \
+ TAG_NAME="$$i" \
+ TAG_LINK="./@$$i.html" \
+ envsubst < templates/tag_link.html >> $@; \
+ done; \
+ envsubst < templates/tag_link_footer.html >> $@; \
envsubst < templates/article_footer.html >> $@; \
envsubst < templates/footer.html >> $@; \
diff --git a/templates/tag_link.html b/templates/tag_link.html
new file mode 100644
index 000000000..49cc68ce5
--- /dev/null
+++ b/templates/tag_link.html
@@ -0,0 +1 @@
+<a href="$TAG_LINK">$TAG_NAME</a>
diff --git a/templates/tag_link_footer.html b/templates/tag_link_footer.html
new file mode 100644
index 000000000..38bf9e7de
--- /dev/null
+++ b/templates/tag_link_footer.html
@@ -0,0 +1 @@
+</i></p>
diff --git a/templates/tag_link_header.html b/templates/tag_link_header.html
new file mode 100644
index 000000000..c56658589
--- /dev/null
+++ b/templates/tag_link_header.html
@@ -0,0 +1 @@
+<p><i> Recipe tags: