From 3ee8a6dbcdc3c8afaea2b83fdc2437b8868c60d1 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Thu, 22 Feb 2024 21:38:57 +0100 Subject: Import some basic files --- GNUmakefile | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 GNUmakefile (limited to 'GNUmakefile') diff --git a/GNUmakefile b/GNUmakefile new file mode 100644 index 0000000..852c272 --- /dev/null +++ b/GNUmakefile @@ -0,0 +1,26 @@ +.PHONY: check clean serve watch + +MAKEFLAGS := -j$(shell nproc) +export PATH := $(PATH):./bin +export LANG := en_US.UTF-8 + +srcs := $(shell find src -type f -name 'index.gsp') +dsts := $(srcs:%.gsp=%.html) + +all: $(dsts) + +%.html: %.gsp + m4 -P -Iinclude m4/* $< | gsp >$@ + +check: + find src -name '*.gsp' -exec \ + aspell --home-dir=./ --ignore-case check {} \; + +clean: + find . -name '*.html' -delete + +serve: + darkhttpd src --daemon + +watch: + git ls-files --others | entr -n $(MAKE) -- cgit v1.2.3