From 68652958a5c45ec69e5d04fa0b586ad0051d3942 Mon Sep 17 00:00:00 2001 From: la-ninpre Date: Fri, 6 Nov 2020 19:29:02 +0300 Subject: Makefile: add release target this is kinda messy, but supposed to work when tag happens. --- .gitignore | 2 ++ Makefile | 22 ++++++++++++++++------ fonts/otf/Putnik.otf | Bin 27772 -> 27772 bytes fonts/ttf/Putnik.ttf | Bin 49096 -> 49096 bytes 4 files changed, 18 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 5ceb386..43400b3 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ venv +*.zip +*.tar.gz diff --git a/Makefile b/Makefile index bf521df..a07ae3c 100644 --- a/Makefile +++ b/Makefile @@ -1,8 +1,10 @@ -FONTNAME=Putnik +FONT_NAME=Putnik +FONT_VERSION=$(shell git describe --abbrev=4) +RELEASE=$(FONT_NAME)-$(FONT_VERSION) OUT_DIR=fonts -UFO_SRC=sources/$(FONTNAME).ufo -TTF=fonts/ttf/$(FONTNAME).ttf -OTF=fonts/otf/$(FONTNAME).otf +UFO_SRC=sources/$(FONT_NAME).ufo +TTF=fonts/ttf/$(FONT_NAME).ttf +OTF=fonts/otf/$(FONT_NAME).otf all: ttf otf @@ -14,7 +16,15 @@ otf: $(OTF) $(OTF): $(UFO_SRC) fontmake -u $(UFO_SRC) -o otf --output-dir fonts/otf/ +release: release-tar release-zip + +release-tar: ttf otf + tar -cvf $(RELEASE).tar.gz $(OTF) $(TTF) LICENSE + +release-zip: ttf otf + zip -j $(RELEASE).zip $(OTF) $(TTF) LICENSE + clean: - -rm $(TTF) $(OTF) + -rm $(TTF) $(OTF) $(RELEASE).* -.PHONY: clean +.PHONY: all release clean diff --git a/fonts/otf/Putnik.otf b/fonts/otf/Putnik.otf index 0f828cf..5278289 100644 Binary files a/fonts/otf/Putnik.otf and b/fonts/otf/Putnik.otf differ diff --git a/fonts/ttf/Putnik.ttf b/fonts/ttf/Putnik.ttf index fd4f5c9..163ed90 100644 Binary files a/fonts/ttf/Putnik.ttf and b/fonts/ttf/Putnik.ttf differ -- cgit v1.2.3