summaryrefslogtreecommitdiffstats
path: root/Makefile
blob: ffef2f444c9bf49e6a0a90ff7e95e1316348f2dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# The server's deploy hook runs `make` in the checkout, and nginx serves the .gz
# copies directly (gzip_static). Every page, stylesheet, script and SVG gets a
# compressed copy next to the original. The default target must stay `all`.
SRC_FILES := $(shell find . -path ./.git -prune -o -type f \( -name "*.html" -o -name "*.css" -o -name "*.js" -o -name "*.svg" -o -name "*.md" \) -print)
GZ_FILES  := $(SRC_FILES:=.gz)

all: $(GZ_FILES)

%.gz: %
	gzip -k -f $<

clean:
	rm -f $(GZ_FILES)

.PHONY: all clean