From 25afb0bde9b8a2c064135a534231c232a461b341 Mon Sep 17 00:00:00 2001 From: Joris Date: Sun, 16 Feb 2020 22:45:07 +0100 Subject: Set up a first version of tabata timer --- Makefile | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..6c9a2b3 --- /dev/null +++ b/Makefile @@ -0,0 +1,22 @@ +export PATH := node_modules/.bin:$(PATH) + +build: public/main.js + +public/main.js: node_modules $(shell find src \( -type d -o \( -type f -a -regex ".*\.ml" \) \)) + @echo "Building $@" + @bsb -make-world + @rollup --config rollup.config.js + @terser $@ --output $@ --compress --mangle + +node_modules: package.json + @bsb -init init + @mv init/node_modules . + @rm -rf init + @npm install + @touch -c node_modules + +clean: + @echo "Cleaning" + @rm -f public/main.js + @rm -rf node_modules lib + @find src -name '*.bs.js' -exec rm {} \; -- cgit v1.2.3