website/Makefile

23 lines
474 B
Makefile
Raw Permalink Normal View History

2024-11-18 14:21:13 +00:00
enmd = $(wildcard src/en/*.md)
enhtml = $(patsubst src/en/%.md,pages/en/%.html,$(enmd))
srmd = $(wildcard src/sr/*.md)
srhtml = $(patsubst src/sr/%.md,pages/sr/%.html,$(srmd))
out: $(enhtml) $(srhtml)
$(srhtml): $(srmd) | pages/sr/.gitignore
pages/sr/%.html: src/sr/%.md
lowdown $< > $@
$(enhtml): $(enmd) | pages/en/.gitignore
pages/en/%.html: src/en/%.md
lowdown $< > $@
pages/%/.gitignore:
mkdir -p $(dir $@)
echo '*' > $@
.PHONY: clean
clean:
$(RM) -r pages/