summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorSylvain Gauthier <s94.gauthier@laposte.net>2021-03-13 17:34:13 +1100
committerSylvain Gauthier <s94.gauthier@laposte.net>2021-03-15 10:36:14 +1100
commit81ee1e91c4bc8d996e586eeff1eb6638656d3fc5 (patch)
tree7406fe90e833d04dd762cfab4a803d6b7635f096 /Makefile
parent5708338d4a4328664c7e5c7f8666098b8189e14c (diff)
downloadbased.cooking-81ee1e91c4bc8d996e586eeff1eb6638656d3fc5.tar
based.cooking-81ee1e91c4bc8d996e586eeff1eb6638656d3fc5.tar.gz
based.cooking-81ee1e91c4bc8d996e586eeff1eb6638656d3fc5.tar.lz
based.cooking-81ee1e91c4bc8d996e586eeff1eb6638656d3fc5.tar.xz
based.cooking-81ee1e91c4bc8d996e586eeff1eb6638656d3fc5.zip
add taglist function
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 20b82e4a5..be6e80014 100644
--- a/Makefile
+++ b/Makefile
@@ -16,7 +16,7 @@ BLOG_FEEDS ?= rss atom
BLOG_SRC ?= articles
-.PHONY: help init build deploy clean
+.PHONY: help init build deploy clean taglist
ARTICLES = $(shell git ls-tree HEAD --name-only -- $(BLOG_SRC)/ 2>/dev/null)
TAGFILES = $(patsubst $(BLOG_SRC)/%.md,tags/%,$(ARTICLES))
@@ -184,3 +184,6 @@ blog/atom.xml: $(ARTICLES)
"`sed -n '1d;/^$$/{2{d;b};q};p' < $$FILE`"; \
done >> $@
printf '</feed>\n' >> $@
+
+taglist:
+ grep -RIh '^;tags:' src | cut -d' ' -f2- | tr ' ' '\n' | sort | uniq