nomnom/static/img/photo/Makefile
2021-01-10 18:17:55 +01:00

13 lines
273 B
Makefile

PHOTOS_ORIG = $(wildcard *.orig.jpg)
PHOTOS_MIN = $(patsubst %.orig.jpg,%.min.jpg,$(PHOTOS_ORIG))
MIN_WIDTH = 800
CONVERT_OPTIONS = -quality 75
all: $(PHOTOS_MIN)
%.min.jpg: %.orig.jpg
convert "$<" -size '$(MIN_WIDTH)x' $(CONVERT_OPTIONS) "$@"
clean:
rm -f *.min.jpg