From 689c3955db0f764b0676f8ae19e7db5d895c137e Mon Sep 17 00:00:00 2001 From: Patrick Jahns Date: Thu, 23 Aug 2018 09:26:09 +0200 Subject: [PATCH] added ability to build the app --- .gitignore | 1 + Makefile | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 .gitignore create mode 100644 Makefile diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c795b05 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +build \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..1234df9 --- /dev/null +++ b/Makefile @@ -0,0 +1,31 @@ +SHELL := /bin/bash + +# directories +build_dir=build +dist_dir=$(build_dir)/dist +app_name=$(notdir $(CURDIR)) +package_dir=$(CURDIR)/$(dist_dir)/$(app_name) + +# start with displaying help +.DEFAULT_GOAL := help + +help: + @fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//' + + + +## +## Build +##-------------------------------------- + + +.PHONY: dist +dist: ## create releasable tarball +dist: + rm -rf $(dist_dir) + mkdir -p $(dist_dir) + tar -czf $(dist_dir)/$(app_name).tar.gz \ + --exclude-vcs \ + --exclude="../$(app_name)/build" \ + ../$(app_name) +