.PHONY: all install SOURCES_SRC:=$(shell find src -type f ) LIBS_SRC:=$(shell find lib -type f ) REPOTOOL_PATH ?= ${HOME}/repo all: dist/repotool install: dist/repotool shell/zsh/repotool.zsh shell/zsh/repotool.plugin.zsh mkdir -p ${REPOTOOL_PATH}/.bin/ mkdir -p ${REPOTOOL_PATH}/.shell/ install dist/repotool ${REPOTOOL_PATH}/.bin/ install shell/zsh/repotool.zsh shell/zsh/repotool.plugin.zsh ${REPOTOOL_PATH}/.shell/ dist/repotool: $(SOURCES_SRC) $(LIBS_SRC) main.lua @mkdir -p dist luabundler bundle main.lua -p "./src/?.lua" -p "./lib/?.lua" -o dist/repotool @sed -i "1i#!/usr/bin/env luajit" "dist/repotool" chmod +x dist/repotool