.PHONY: all node-deps clean run TARGET=public/elm.js SOURCE=src/App.elm ELM_FILES = $(shell find src -type f -name '*.elm') ELM = ./bin/elm ELMMAKE_FLAGS = ifeq ($(DEBUG),1) ELMMAKE_FLAGS += --debug endif all: $(TARGET) $(ELM): mkdir -p ./bin curl -sL https://github.com/elm/compiler/releases/download/0.19.1/binary-for-linux-64-bit.gz \ | gunzip > $@ chmod +x $@ $(TARGET): $(ELM_FILES) $(ELM) $(ELM) make $(ELMMAKE_FLAGS) $(SOURCE) --output $@ clean-deps: rm -rf bin rm -rf elm-stuff clean: rm -f $(TARGET) rm -rf elm-stuff/build-artifacts