Makefile: incremental builds 🎉
This commit is contained in:
parent
4cd7b8b118
commit
8890abfbf6
28
Makefile
28
Makefile
|
@ -1,17 +1,23 @@
|
||||||
PAGES = index.html rules.html donate.html
|
PAGES_SRC = index.html rules.html donate.html
|
||||||
|
PAGES_BUILD = $(addprefix build/tor/,$(PAGES_SRC)) $(addprefix build/clearnet/,$(PAGES_SRC))
|
||||||
|
|
||||||
all: $(PAGES) symlinks
|
all: $(PAGES_BUILD) symlinks
|
||||||
|
|
||||||
.PHONY: symlinks clean
|
.PHONY: clean
|
||||||
|
|
||||||
symlinks:
|
symlinks: build/tor/static build/clearnet/static
|
||||||
ln -sf ../../static build/tor/
|
|
||||||
ln -sf ../../static build/clearnet/
|
build/tor/static:
|
||||||
|
ln -s ../../static build/tor/
|
||||||
|
|
||||||
|
build/clearnet/static:
|
||||||
|
ln -s ../../static build/clearnet/
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f $(addprefix build/tor/,$(PAGES))
|
rm -rf $(PAGES_BUILD)
|
||||||
rm -f $(addprefix build/clearnet/,$(PAGES))
|
|
||||||
|
|
||||||
%.html: %.j2.html base.j2.html
|
build/tor/%.html: %.j2.html base.j2.html
|
||||||
j2 -D site tor $< > build/tor/$@
|
j2 -D site tor $< > $@
|
||||||
j2 -D site clearnet $< > build/clearnet/$@
|
|
||||||
|
build/clearnet/%.html: %.j2.html base.j2.html
|
||||||
|
j2 -D site clearnet $< > $@
|
||||||
|
|
Loading…
Reference in New Issue