add make creature command

This commit is contained in:
Malin Freeborn 2024-06-05 01:21:02 +02:00
parent bba6c6effa
commit 065186538a
Signed by: andonome
GPG Key ID: 52295D2377F4D70F
1 changed files with 17 additions and 0 deletions

View File

@ -1,9 +1,26 @@
help:
@echo "Options:"
@echo "\tmake pdf"
@echo "\tmake creature"
.PHONY: pdf .PHONY: pdf
pdf: overview.pdf pdf: overview.pdf
rubbish/: rubbish/:
mkdir rubbish mkdir rubbish
RANDOM != date +%s
TMP := /tmp/$(RANDOM).md
NAME := $(shell head -1 $(TMP) 2>/dev/null| tail -c+3)
.PHONY: creature
creature: stats/$(NAME).md
$(TMP):
cp stats/template.md $(TMP)
$$EDITOR $(TMP)
stats/$(NAME).md: $(TMP)
mv $(TMP) stats/$(NAME).md
overview.pdf:| rubbish/overview.pdf overview.pdf:| rubbish/overview.pdf
ln rubbish/overview.pdf overview.pdf ln rubbish/overview.pdf overview.pdf
rubbish/overview.pdf: overview.tex rubbish/overview.pdf: overview.tex