filter = $(shell cowsay -l | sort -R | head -1) zoo = $(patsubst Forts/fortune_%.md,Zoo/animal-%.md,$(forts)) $(zoo): Zoo/animal-%.md: Forts/fortune_%.md @mkdir -p $(@D) echo '```' > $@ cat $< | cowsay -f $(filter) >> $@ echo '```' >> $@ progs += forts progs += $(zoo) dross += Zoo/