aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile22
1 files changed, 16 insertions, 6 deletions
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