castle/Makefile
Auke Kok 495c1c9003 Add a make dist script to make actual releases that work.
contentdb is just pointing at an empty modpack, so, this is
badly needed. After making a tar, it should be gzipped and for
convenience, converted to zip for windows users, and then
uploaded to github as a new release.
2019-01-29 17:18:42 -08:00

19 lines
666 B
Makefile

PROJECT ?= castle_modpack
VERSION ?= $(shell git describe --tags --always)
all:
@echo "Nothing to do. Maybe you want `make dist` instead?"
dist:
@echo Running git archive...
git archive --prefix=$(PROJECT)-$(VERSION)/ -o $(PROJECT)-$(VERSION).tar $(VERSION)
@echo Running git archive submodules...
p=`pwd` && (echo .; git submodule foreach) | while read entering path; do \
temp="$${path%\'}"; \
temp="$${temp#\'}"; \
path=$$temp; \
[ "$$path" = "" ] && continue; \
(cd $$path && git archive --prefix=$(PROJECT)-$(VERSION)/$$path/ HEAD > $$p/tmp.tar && tar --concatenate --file=$$p/$(PROJECT)-$(VERSION).tar $$p/tmp.tar && rm $$p/tmp.tar); \
done